-
Notifications
You must be signed in to change notification settings - Fork 22
Document debugging in Chrome and VSCode #37
Comments
I cannot add breakpoints in a Svelte components using Debugger for Chrome VSCode extension. It seems that it doesn't know about Svelte yet and I can't figure out if there's a configuration for including file extensions for the debugger to use. I can use |
Adding the following configuration did the trick. For some reason Chrome debugger doesn't allow placing breakpoints in HTML files by default. "debug.allowBreakpointsEverywhere": true |
One thing that might help to get this to work is adding |
@Rich-Harris is there any particular reason why this issue is still open? adding {
"type": "chrome",
"request": "launch",
"name": "Launch Chrome against localhost",
"url": "http://localhost:5000",
"webRoot": "${workspaceFolder}/src"
} to |
Hi all, I can debug a Svelte app with the VSCode debugger with the configuration.
However, I'm not able to debug on VSCode when a Does anyone have a working configuration for this kind of project setup? Am I missing something in the configuration? How do I make sure the current build is configured to generate source maps? Thanks |
CC @frantic0. A good place to start when the Chrome VScode debugger is not playing well with your new set up is the debugger's repo README, especially the general things to try if you're having issues section. Note the tips offered relevant to your current setup.
Sapper's rollup setup uses inline source maps by default. Try switching to external ones: // rollup.config.js
output: {
...config.client.output(),
sourcemap: true,
}
// launch.json
"webRoot": "${workspaceFolder}/demo/__sapper__/dev/client", |
For me adding "/src" part to P. S. I'm using svelte template:
|
See sveltejs/sapper#436
The text was updated successfully, but these errors were encountered: