【发布时间】:2018-02-08 15:24:32
【问题描述】:
根据here,我正在尝试设置 VSCode 以使用 Edge 进行调试,但是,尽管我安装了 VSCode 扩展:Edge 调试器。 VSCode 中的 Launch.json 文件如下:
{
// Use IntelliSense to learn about possible Node.js debug 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": "edge",
"request": "launch",
"name": "Launch Program",
"url": "http://localhost:4200",
"webRoot": "${workspaceRoot}/",
"sourceMaps": true
}
,
{
"name": "attach to my-app",
"type": "edge",
"request": "attach",
"port": 9222,
"url": "http://localhost:4200/",
"webRoot": "${workspaceRoot}/",
"diagnosticLogging": true
}
]
}
我正在从上面的“附加到我的应用程序”选项中启动 VSCode 调试器。 my-app 项目是一个 Angular2 快速入门示例,您可以在 this page 和 code here 上找到。我总是在 VSCode 中遇到“[debugger-for-chrome] 意外的服务器响应(400)”。
如果你对使用 VSCode 调试 Angular2/typescript 项目有任何想法,欢迎留言。
【问题讨论】:
-
我认为Chrome调试器扩展更稳定,如果你可以在Chrome而不是Edge中调试:marketplace.visualstudio.com/…
标签: angular typescript debugging visual-studio-code microsoft-edge