-
-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SvelteKit wizard fails to add sentrySvelteKit
plugin in vite configs that don't directly default-export the config
#362
Comments
Discovered in getsentry/sentry-javascript#8325 |
sentrySvelteKit
pluginsentrySvelteKit
plugin in Turborepo project
Just got this exact same error. |
Yes, that's correct. The setup for vite is very simple though. As a workaround I suggest following code snippet I believe I identified the issue: Currently, we can only handle adding the plugin if the config export is directly exported: export default {
// config object...
} Apparently, const config = {...}
export default config; We should add this; probably help Antfu out and contribute upstream. Regardless, we'll also provide a fallback copy/paste snippet directly in the wizard if we encounter an error so that we can always help out directly in the wizard. Will fix this soon. |
I opened unjs/magicast#69 to fix this upstream in |
sentrySvelteKit
plugin in Turborepo projectsentrySvelteKit
plugin in vite configs that don't directly default-export the config
Environment
What version are you running? Etc.
Steps to Reproduce
Expected Result
Wizard successfully adds
sentrySvelteKit
plugin tovite.config.js
Actual Result
Wizard fails at
vite.config.js
injection with errorProbably some problem with
magicast
. Need to investigate furtherUpdate
This isn't directly related to turborepo but to the structure of the
vite.config.js
. Explanation: #362 (comment)The text was updated successfully, but these errors were encountered: