r/javascript • u/Plorntus • Mar 12 '26
Vite 8 has been released
https://vite.dev/blog/announcing-vite814
u/gajus0 Mar 12 '26
Been using this for months while it was in beta. It's a beast!
Congrats to the team.
7
u/lucax88x Mar 12 '26
I have an existential doubt.
I've been using lingui in all my projects, I guess I'm locked out from rolldown until they don't make it lingui macro plugin work with it, and we don't have an ETA for that.
So, I was wondering, are there other i18n libs that don't suffer this?
Same doubt goes with react-compiler...
→ More replies (1)2
u/manniL Mar 12 '26
you can use react-compiler with Vite 8, but it will be very slow because it is Babel-based. The React team is working on a Rust port though.
2
u/nullvoxpopuli sand was never meant to think Mar 13 '26
you can bisect anything that needs babel with a custom plugin that just checks if a file needs babel, and if not, use oxc -- like here: https://github.com/NullVoxPopuli/limber/blob/c9f91f904a388c77f73adf82a5335edddbd20afc/apps/repl/vite.config.js#L35
2
4
u/Horror-Student-5990 Mar 12 '26
Switching from 7.X to 8 was seamless for me, just had to fix some lines in viteconfig
const name = assetInfo?.name ?? 'asset';
const extType = name.split('.');
5
2
u/omer-m Mar 12 '26
Does switching to rolldown mean less dependency? If so that's a good thing I guess. This one always sneaks in my node_modules as a dependency of vitest.
Since I ship less SPAs these days, I don't have much experience with vite but I believe it's a great toolset.
I just wish next.js was powered by vite too instead of wasting time with turbopack (which is more terrible than webpack imo)
5
u/A1oso Mar 13 '26
Install Size
We want to be transparent about changes to Vite's install size. Vite 8 is approximately 15 MB larger than Vite 7 on its own. This comes from two main sources:
~10 MB from lightningcss: Previously an optional peer dependency, lightningcss is now a normal dependency to provide better CSS minification out of the box.
~5 MB from Rolldown: The Rolldown binary is larger than esbuild + Rollup mainly due to performance optimizations that favor speed over binary size.
We will continue monitoring and working to reduce install size as Rolldown matures.
2
u/manniL Mar 12 '26
Rolldown => no rollup and esbuild (+ some rollup plugins are built-in features), so yes, less deps
1
u/Educational_Mark7790 Mar 19 '26
Vite 8 has been a huge disappointment:
https://github.com/vitejs/vite/issues/21939
Build filesizes have doubled... No build speed gain is worth that...
I would take a slightly longer build time for half the filesize any day
3
u/itistimetorise Mar 19 '26
still no reproduction added to your ticket, no objective pointers, no one on earth knows what you are doing except yourself. How would you expect someone to help you? Nah you can't be serious.
21
u/averageFlux Mar 12 '26
Finally! Looking forward to upgrade everything. What a great effort