Visual Studio Code debugging chrome, Breakpoints wont hit

后端 未结 4 2246
深忆病人
深忆病人 2021-02-15 13:15

I have a Angular2/typescript app I am developing in VSCode. I use Gulp to build the typescript files and gulp-sourcemap to create map files. Attaching/launching chrome works wel

4条回答
  •  青春惊慌失措
    2021-02-15 14:15

    I totally agree with RVCA18. It's about the webRoot Setting that was wrong. I had VS-Code ${workspaceRoot} pointing to a subfolder (just because I opened the project like that and had no script in the top-level folder). Since the index.html that is launched is in the top level folder I had to set the following Option in launch.json

    "webRoot": "${workspaceRoot}/.."
    

提交回复
热议问题