Skip to content

Not working anymore after changed from svelte-kit dev to vite dev #1417

Answered by stinger5
stinger5 asked this question in Q&A
Discussion options

You must be logged in to vote

Okay, I solved it myself.
First, I forgot to tell vite to avoid externalizing "@carbon/charts" when building for production. Second, I added also "carbon-components" to this section. After I added this to my vite.config.js, it builds successful:
ssr: {
noExternal: [
production && '@carbon/charts',
production && 'carbon-components'
].filter(Boolean),
}
Hope it helps for others :)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by stinger5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant