a program that is used to test and debug other programs (the "target" program)
"debugger" statement
run your app in debug mode via:
node debug [your app]
setBreakpoint() – sb()
setBreakpoint(line) – sb(line)
clearBreakpoints() – cb()
repl , watch(expression)
continue – cont, c
step – next, n
step in – step, s
step out – out, o
run your app in debug mode via:
node --debug [your app]
Node Inspector allows you to use the DevTools user interface with the native Node debugger
npm install -g node-inspector
node-debug app.js
Problem:
The built-in Node debugger uses a protocol called V8-Debug
while DevTools uses the Chrome Debugging Protocol
Solution:
node --inspect app.js
node --inspect=9222 app.js
VS Code has built-in debugging support for Node.js runtime
https://7chan.org/pr/src/debugging_-_the_9_indispensable_rules_for_finding_.pdf