You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Svelte/SvelteKit config still goes in svelte.config.js (otherwise e.g. editor integrations won't know how to use the right preprocessors), but if a vite.config.js exists then config.kit.vite will be ignored.
The value of this is that we can use things like vitest without any weirdness.
Describe the proposed solution
If we decide that we like this approach (and I think we probably will) then it would make sense to make some changes:
Make vite.config.js mandatory
Add it to project templates
Get rid of config.kit.vite
Move @sveltejs/kit/experimental/vite to @sveltejs/kit/vite or @sveltejs/vite-plugin-sveltekit
More controversially, we might want to get rid of svelte-kit dev/build/preview in favour of using vite dev/build/preview. This would mean that SvelteKit itself would no longer have a dependency on Vite, other than in the plugin; apps themselves would need to have a devDependency on vite
Consequently, figure out how to handle versions. It's likely that SvelteKit will expect a particular version of Vite, which might mean it needs to become a peerDependency if it's no longer a dependency (though if it's possible to avoid depending on a specific version, that would be ideal)
Alternatives considered
Keep things as they are
Importance
would make my life easier
Additional Information
We should spend a bit of time with @sveltejs/kit/experimental/vite before leaping to any conclusions.
The text was updated successfully, but these errors were encountered:
Describe the problem
We just merged #5094, which means it's possible to think of SvelteKit as just another Vite plugin:
Svelte/SvelteKit config still goes in
svelte.config.js
(otherwise e.g. editor integrations won't know how to use the right preprocessors), but if avite.config.js
exists thenconfig.kit.vite
will be ignored.The value of this is that we can use things like vitest without any weirdness.
Describe the proposed solution
If we decide that we like this approach (and I think we probably will) then it would make sense to make some changes:
vite.config.js
mandatoryconfig.kit.vite
@sveltejs/kit/experimental/vite
to@sveltejs/kit/vite
or@sveltejs/vite-plugin-sveltekit
svelte-kit dev/build/preview
in favour of usingvite dev/build/preview
. This would mean that SvelteKit itself would no longer have a dependency on Vite, other than in the plugin; apps themselves would need to have a devDependency onvite
Alternatives considered
Keep things as they are
Importance
would make my life easier
Additional Information
We should spend a bit of time with
@sveltejs/kit/experimental/vite
before leaping to any conclusions.The text was updated successfully, but these errors were encountered: