ItalyPaleAle / svelte-spa-router

Router for SPAs using Svelte 3
MIT License
1.53k stars 105 forks source link

vite support #291

Closed laoshaw closed 1 year ago

laoshaw commented 1 year ago

"Starting with version 3.0, svelte-spa-router supports dynamically-imported components (via the import() construct). The advantage of using dynamic imports is that, if your bundler supports that, you can enable code-splitting and reduce the size of the bundle you send to your users. This has been tested with bundlers including Rollup and Webpack."

does svelte-spa-router support vite? if so would love to see document about it, even more, about how to use it.

ItalyPaleAle commented 1 year ago

Yes it's been tested successfully with esbuild and vite. Nothing special to use it - just import it like you would any other dependency!