Debugging with NodeJS

headbang

I’ve found debugging to be tricky with Node, until today. Running with the `–inspect` flag is pretty cool, mind you it’s “experimental” and “may be disconued at any time” !

Recap: `$ node –inspect yourFile.js`

Then node will give you a CHROME-ONLY url to debug your script. I highly recommed enabling the auto-break feature in the inspector tools. If you’re not familiar that, look at pausing on exceptions in chrome.

Also, here’s a good tip for reusing the same web debug session without have to copy/paste the inspection url every time