Visual Studio 2017 CE 中的 TypeScript 调试不起作用
TypeScript debugging in Visual Studio 2017 CE doensn't working
我有 angular 客户端的 WebApi 解决方案。
早些时候,我能够在我的打字稿文件中设置断点并使用 Chrome 调试它们。
很长一段时间我没有使用这个解决方案,但现在我需要。
当我设置断点时,我会收到警告消息:"The breakpoint will not currently be hit. Breakpoint set but not yet bound".
我已将 Visual Studio 2017 更新到最新版本 (15.9.17),但这没有帮助。
知道如何在 Visual Studio 中调试类型脚本吗?
试试这个。
在 VS 代码中,转到调试 -> 开始调试 -> 添加配置
{
"version": "0.2.0",
"configurations": [
{
"name": "Node Inspector",
"type": "node",
"request": "launch",
"args": ["${workspaceRoot}/src/index.ts"],
"runtimeArgs": ["-r", "ts-node/register"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"internalConsoleOptions": "openOnSessionStart",
"env": {
"TS_NODE_IGNORE": "false"
}
}
]
}
和运行它。
来自 https://gist.github.com/cecilemuller/2963155d0f249c1544289b78a1cdd695
希望对您有所帮助。
我决定将WebApi项目和ClientApp拆分成两个不同的repository,在更合适和舒适的环境中继续开发客户端,我选择了WebStorm
我有 angular 客户端的 WebApi 解决方案。 早些时候,我能够在我的打字稿文件中设置断点并使用 Chrome 调试它们。 很长一段时间我没有使用这个解决方案,但现在我需要。 当我设置断点时,我会收到警告消息:"The breakpoint will not currently be hit. Breakpoint set but not yet bound".
我已将 Visual Studio 2017 更新到最新版本 (15.9.17),但这没有帮助。
知道如何在 Visual Studio 中调试类型脚本吗?
试试这个。
在 VS 代码中,转到调试 -> 开始调试 -> 添加配置
{
"version": "0.2.0",
"configurations": [
{
"name": "Node Inspector",
"type": "node",
"request": "launch",
"args": ["${workspaceRoot}/src/index.ts"],
"runtimeArgs": ["-r", "ts-node/register"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"internalConsoleOptions": "openOnSessionStart",
"env": {
"TS_NODE_IGNORE": "false"
}
}
]
}
和运行它。
来自 https://gist.github.com/cecilemuller/2963155d0f249c1544289b78a1cdd695
希望对您有所帮助。
我决定将WebApi项目和ClientApp拆分成两个不同的repository,在更合适和舒适的环境中继续开发客户端,我选择了WebStorm