简体   繁体   English

Node.JS Winston日志记录,Visual Studio调试控制台无法打印

[英]Node.JS Winston logging, Visual Studio Debug Console Not Print

When running as "node app" on terminal of visual studio code during winston logging, console log is output. 在Winston日志记录期间,在Visual Studio代码的终端上作为“节点应用程序”运行时,将输出控制台日志。 However, the debug console tab of visual studio does not print the console log. 但是,Visual Studio的调试控制台选项卡不会打印控制台日志。 Why? 为什么?

enter image description here enter image description here 在此处 输入图像描述在 此处 输入图像描述

below is my launch.json the key is "outputCapture": "std", 下面是我的launch.json,关键是"outputCapture": "std",

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "type": "node",
            "request": "launch",
            "name": "Launch Program",
            "outputCapture": "std", //key is this line
            "program": "${workspaceFolder}/bin/www"
        }
    ]
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM