Skip to content

Instantly share code, notes, and snippets.

@k8adev
Created August 6, 2025 22:47
Show Gist options
  • Save k8adev/dd7f40347bd1c1356811f037f50cb4f7 to your computer and use it in GitHub Desktop.
Save k8adev/dd7f40347bd1c1356811f037f50cb4f7 to your computer and use it in GitHub Desktop.
Example configuration for debugging in VSCode (and Cursor) for NestJs
{
"version": "0.2.0",
"configurations": [
{
"name": "Run server",
"type": "node",
"request": "launch",
"runtimeExecutable": "npm",
"runtimeArgs": [
"run",
"start:debug"
],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"restart": true,
"sourceMaps": true,
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
"skipFiles": [
"<node_internals>/**",
"**/node_modules/**",
"**/*.spec.ts",
"**/*.test.ts"
],
"timeout": 30000,
"resolveSourceMapLocations": [
"${workspaceFolder}/**",
"!**/node_modules/**"
],
"env": {
"CACHE_ENABLED": "${input:cacheEnabled}"
}
},
{
"name": "Run REPL",
"type": "node",
"request": "launch",
"runtimeExecutable": "npm",
"runtimeArgs": [
"run",
"repl"
],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"restart": true,
"sourceMaps": true,
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
"skipFiles": [
"<node_internals>/**",
"**/node_modules/**",
"**/*.spec.ts",
"**/*.test.ts"
],
"timeout": 30000,
"resolveSourceMapLocations": [
"${workspaceFolder}/**",
"!**/node_modules/**"
],
"env": {
"CACHE_ENABLED": "${input:cacheEnabled}"
}
}
],
"inputs": [
{
"id": "cacheEnabled",
"description": "Enable cache for development?",
"type": "pickString",
"options": [
{
"label": "Yes (faster, may show stale data)",
"value": "true"
},
{
"label": "No (slower, always fresh data)",
"value": "false"
}
],
"default": "false"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment