-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Closed
Labels
Description
Stack traces on the client side on the dev server are correctly mapped to the source code, but the server-side stack traces are not
In dev mode, if I throw an exception in Nav.svelte, I get this on the server side:
Error: testing stacktrace
at eval (/_app/components/Nav.js:15:8)
at Object.$$render (/web_modules/svelte/internal.js:1343:22)
We should map this back to the Nav.svelte file like happens in Sapper.
On a production build, the client-side stack trace from an error I throw in an on:click looks like this:
Uncaught Error: testing stacktraces
at HTMLButtonElement.<anonymous> (Nav.js:268)
(anonymous) @ Nav.js:268
The server-side stack traces look like:
Error: testing stacktrace
at fn (/Users/andreasehrencrona/projects/svelte/kit/examples/hn.svelte.dev/.svelte/build/unoptimized/server/_app/components/Nav.js:13:8)
I suppose we should map these too?
antony