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

394
Vistas
How to define CLI args before running the app in Launch.json ? (Node.js)

I am trying to specify argument for running the node app. Somehow ,

    role_id=123 secret_id=123 node app

Works. But,

    node app role_id=123 secret_id=123

Doesn't work and gives me missing args error.

When I add these args to launch.json in VsCode , the program runs in the later way , as shown in VSCode Terminal Screenshot. How to run the program in the way , that the args are defined before running node app.

Launch.json looks like this :

{
    "version": "0.2.0",
    "configurations": [
        {
            "args": ["role_id=123", "secret_id=123", "NODE_ENV=test"],
            "type": "node",
            "request": "launch",
            "name": "DEBUG NODE APP",
            "program": "${workspaceFolder}/app.js",
        }
    ]
}
about 4 years ago · Juan Pablo Isaza
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