Winston Logger - NodeJs Debug Console Logs Not Displayed in VSCode

I use the VSCode debugger and winston logger for NodeJS, but I cannot see the output from the application unless I specify the external terminal as follows:

"version": "0.2.0",
"configurations": [
    {
        "type": "node",
        "request": "launch",
        "name": "Launch Program",
        "program": "${workspaceFolder}/server.js",
        "console": "externalTerminal"
    }
]

Is there a way to see this output in the output window, for example, when I run the code using the CodeRunner plugin?

+4
source share
1 answer

When using a registrar that outputs to

process.stdout.write

you can use

"outputCapture": "std" in the launch configuration to also fix this.

+4
source

Source: https://habr.com/ru/post/1691519/


All Articles