Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

213
Vistas
Can I run an npm package without the npm run command?

I would like to run the next.js build process directly from the command line without going over the package.json. Is it possible to run it without npm run?

Instead of running npm run build

I would like to run next build directly on the command line.

Cheers for the help.

about 4 years ago · Juan Pablo Isaza
3 Respuestas
Responde la pregunta

0

you can go to package.json and then change the scripts.

"build": "next build",

about 4 years ago · Juan Pablo Isaza Denunciar

0

I figured it out so basically whatever you add at the end of the npm run command gets attached to the npm run command:

"scripts": {
    "dev": "next dev",
    "build": "next build",
    "export": "next build && next export -o",
  }

Now I can run

npm export jane-doe-directory

And the application will be exported to that directory.

about 4 years ago · Juan Pablo Isaza Denunciar

0

If you look inside your project's node_modules/.bin directory, you should see an alias for the next command. So if you want to run next build directly without using npm...

Bash:

./node_modules/.bin/next build

Windows Command Prompt:

.\node_modules\.bin\next.cmd build
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda