Debugging information on ExpressJS about all of the cycle of a web application is something simple. ExpressJS uses the debug NPM module internally to log information. Unlike console.log, debug logs can easily be disabled on production mode.
Debugging your ExpressJS web application
Getting ready
In this recipe, you will see how to debug your ExpressJS web application. Before you start, create a new package.json file with the following content:
{ "dependencies": { "debug": "3.1.0", "express": "4.16.3" } }
Then, install the dependencies by opening a terminal and running:
npm install