项目根目录下新建 .vscode 文件夹,然后在该文件夹下创建launch.json
launch.json文件内容如下
{ "version": "0.2.0", "configurations": [ { "type": "node", "request": "launch", "name": "Launch program", "program": "${workspaceFolder}\\dist\\main.js", }, { "type": "node", "request": "attach", "name": "Attach to Port", "address": "localhost", "port": 5858 } ] }
点击debug
作者:Work Hard Work Smart
出处:http://www.cnblogs.com/linlf03/
欢迎任何形式的转载,未经作者同意,请保留此段声明!