'ExpressJS not showing debug messages

I am using ExpressJS and would like to display internal debug messages, like here https://expressjs.com/en/guide/debugging.html.

When I am using this command in VS Code (Windows Powershell) "`set DEBUG=express:*; node ./dist/app.js" it is starting my Node/Express Server, however it does not display any debug messages. Do I have to add something to my code so it works?



Solution 1:[1]

"Express uses the debug module internally to log information about route matches, middleware functions that are in use, application mode, and the flow of the request-response cycle." Do you have this package: https://www.npmjs.com/package/debug And there is no semicolon between the statements.

Solution 2:[2]

I tried the same in windows command prompt and it worked there just exchanged the semicolon for an ampersand.

set DEBUG=express:* & node ./dist/app.js

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Michaƫl
Solution 2 Sebastian Salletmayer