VS Code Debugging and Tasks/Background watch task

Mark long-running watchers as background tasks.

Section: tasks.json

Background watch task

json
json
{
  "label": "npm: dev",
  "type": "shell",
  "command": "npm run dev",
  "isBackground": true,
  "problemMatcher": []
}

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing tasks.json
NPM build task
Run npm build as a task.
OpenIn sheetjsonsame section
Run build task shortcut
Run default build task quickly.
OpenIn sheettextsame section
Toggle breakpoint
Set or remove a breakpoint.
Basic Node launch config
Debug the current Node file.
Step over
Execute current line without stepping into functions.
Attach to existing Node process
Attach debugger to a process already running with inspect.