Debugging the Node.js API
While debugging the Angular app, we have focused on exploring the debugging extension for Chrome and also explored several different debugging features provided by VS Code. Apart from the Angular frontend, the job order system is spread over multiple microservices developed in different languages. Let's discuss how we can debug these multiplatform backends, starting off with Node.js APIs.
VS Code provides out-of-the-box support for Node.js. It's possible to debug code written in JavaScript and TypeScript without the need to install third-party extensions.
Creating the launch configuration
To set up the launch configuration for the Node.js project, we will follow the same approach and create a launch configuration, like this:
- Open the Node.js project folder and press Ctrl + Shift + P to open the command palette. Type
Open launch.json
, as shown in the following screenshot, and press Enter to proceed: