【发布时间】:2018-09-04 10:05:13
【问题描述】:
我正在尝试从 Visual Studio cod 调试我的 Angular 代码。已安装插件 Debugger for chrome 并添加了 Google Chrome 中用于将调试器附加到进程所需的所有配置。
下面是launch.json文件中的配置。
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "attach",
"name": "Attach to Chrome",
"port": 9222,
"url":"http://localhost:4200*",
"webRoot": "${workspaceFolder}"
},
{
"type": "node",
"request": "launch",
"name": "Launch Program",
"program": "${workspaceFolder}\\serve"
}
]
将其附加到 chrome 进程后,不会命中断点。控件转到从源映射中的内联内容提供的只读文件。附上下面的快照。
如果我遗漏了什么,请告诉我。我真的需要让这个工作。
【问题讨论】:
标签: javascript typescript debugging visual-studio-code