Tutorials

Install node-debugger in Atom and debug a Node.js application

Here is an easy way to debug your Node.js application with Google Chrome.

1

Install the package node-debugger in the Atom editor.

 

2

Now lets configure node-debugger. There are different things you can configure. I only changed the Debug Port to a different one. Important is that you add –inspect-brk inside the Node Args field. And of course you have to specify the Node Path. Since I was trying it from a Windows machine I entered C:\Program Files\nodejs\node.exe. But this really depends on where it is installed on your machine.

 

3

Open your application and press F5. I was not able to debug the application inside the Atom editor but I was able to enter in Google Chrome the url: chrome://inspect. On the opened page I was able to click on a link Open dedicated DevTools for Node. If you click on it a popup opens which is showing the source code. Now you can start debugging 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *