Last active
February 4, 2021 16:04
-
-
Save abdulwahidgul24085/33481e84254c5458fc8f61817b9e12a3 to your computer and use it in GitHub Desktop.
Nodejs Vscode Debugger and Envfile link
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This runs the nodejs with vscode using nodemon for auto refresh on save. For this we need to install nodemon globally with {npm i -g nodemon} | |
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"name": "Launch server.js via nodemon", | |
"type": "node", | |
"request": "launch", | |
"runtimeExecutable": "nodemon", | |
"program": "${workspaceFolder}\\_express\\index.js", <- the root file to run the index.js, app.js, or server.js | |
"console": "integratedTerminal", | |
"internalConsoleOptions": "neverOpen", | |
"skipFiles": ["<node_internals>/**"], | |
"envFile": "${workspaceFolder}/_express/.env" <- set a .env files to utilize an external Env files inlcusion. | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment