5 ms·
Never start with Webpack. Use Vite with a template and go from there.
by cageface 2y ago
Never start with Webpack. Use Vite with a template and go from there.
- incrudible 2y agoOr just go straight to esbuild. I've found vite just makes things more complicated and slower. Particularly, the "smart reloading" breaks in subtle ways and turning every source file into a request doesn't scale well. This can probably be configured away somehow, but again, that just makes things more complicated.
- CuriouslyC 2y agoRemix. Vite done right, mostly pre-configured out of the box.
- Aeolun 2y agoIf you want to spend a minute or two waiting before your server is back up after making any kind of change, Remix sounds about right. My project is relatively tiny too. I’ve never regretted a choice more than Remix.
- CuriouslyC 2y agoMy projects reload instantly in WSL, what environment are you using?
- julik 2y agoA minute or two? A sizeable Rails web app I am working on takes maybe 5 seconds to start...
- CharlesW 2y ago> Remix. Vite done right… Remix is moving to Vite as its default compiler. https://remix.run/docs/en/main/guides/vite https://remix.run/docs/en/main/guides/vite
- CuriouslyC 2y agoI'm aware, I've been on the experimental vite branch for a while. It is literally "vite, done right"
- WuxiFingerHold 2y agoVue, Nuxt or Svelte are even better. No need to waste time and energy with React and it's peculiarities. However, if you want or must React, then Remix, hands down.
- CuriouslyC 2y agoWhile I very much like svelte, it's not fully mature yet and it doesn't have a very deep ecosystem, plus the additional hiring time/cost basically means building anything other than a small scale solo project with it is going to end you up in the red. On the Vue vs React debate, honestly it comes down to preferring templates vs components. Vue is simpler but there are good reasons for a lot of the React complexity, and React still has a stronger ecosystem and more developers.
- mardifoufs 2y agoBut then you have to waste time with vue/sveltes particularities ;). It's just a matter of what you're used to imo
- chuckadams 2y agoThe request-per-module thing only happens with the Vite dev server: production builds are bundled with rollup similar to webpack.
- csomar 2y agoI'd make the exact opposite suggestion: Always use WebPack. There will be a package in the future that has a particular WebPack configuration to make; and you don't want to figure out how to do that in another bundler.
- HumanOstrich 2y agoNo thanks. Avoiding those hypothetical future packages is a better tradeoff.