Using Angular 13 / Chrome 111 / VSCode 1.76.1 / Node 16.19.1
I'm experiencing a new inability to bind breakpoints in VSCode after my code has live-reloaded.
Here's the configuration that was working yesterday in my launch.json
:
"configurations": [
{
"name": "Client: Launch & Attach",
"type": "chrome",
"request": "launch",
"url": "xxx",
"webRoot": "${workspaceFolder}",
//"preLaunchTask": "run_server"
"skipFiles": [
"${workspaceFolder}/node_modules/**/*.js",
"${workspaceFolder}/lib/**/*.js",
"${workspaceFolder}\\node_modules\\**\\*.js",
"${workspaceFolder}\\lib\\**\\*.js",
"<node_internals>/**/*.js",
"<node_internals>\\**\\*.js",
"*.html"
]
}
]
Beginning today, when I build the project, I'm able to place breakpoints and debug normally. As soon as I save any changes to a project file, the Angular CLI launch command running in my terminal tells me that it's "rebuilding application bundles." Once the page is ready again, I cannot bind any breakpoints. If I place a breakpoint and reload the page that I'm on, the page will keep loading indefinitely. If I try to run the configuration from my launch.json
to launch chrome and attach, the active tab keeps loading indefinitely.
Strangely, killing the chrome instance, then killing the ng serve
process running in the terminal, then restarting the ng serve
process doesn't always fix the inability to bind breakpoints.
Sometimes it works after doing those steps, sometimes I have to fully restart VSCode, sometimes I can't do anything to make it work, and then suddenly it works again. I can't identify a pattern beyond what I've described.
Where can I see error messages that will help me debug this?