Skip to content

Instantly share code, notes, and snippets.

@anastasiya29
Last active April 16, 2021 16:52
Show Gist options
  • Save anastasiya29/ed89d4abe67d61065f50a88b69fa25b6 to your computer and use it in GitHub Desktop.
Save anastasiya29/ed89d4abe67d61065f50a88b69fa25b6 to your computer and use it in GitHub Desktop.
VSCode debugging configurations
// Debug a process running in the browser
{
"name": "Chrome",
"type": "chrome",
"request": "launch",
"url": "http://localhost:3000",
"webRoot": "${workspaceFolder}"
},
// Start debugging from a specific JS file
{
"type": "node",
"request": "launch",
"name": "Name of your debug task",
"program": "${workspaceRoot}/path/to/your/script.js",
},
// Start debugging from a specific npm script
{
"name": "npm run script",
"type": "node",
"request": "launch",
"cwd": "${workspaceRoot}/packages/my-app",
"runtimeExecutable": "npm",
"runtimeArgs": ["run-script", "build" /*, "--preserve-symlinks" */], // if degugging across symlinked projects
"port": 5858,
"resolveSourceMapLocations": [
"${workspaceFolder}/**",
"!**/node_modules/**"
],
"console": "integratedTerminal",
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment