Analyzing Rspack performance bottlenecks revealed stark differences between large real complexand small simple projects. Small projects often bottleneck on Rust tools, while real-world large projects typically bottleneck on JS tools (like Less, Sass, Tailwind、custom plugin). 🤣
TypeScript 5.5 RC is now out to try! We're looking for feedback on inferred type predicates, JSDoc imports, regex checking, ${configDir}, isolatedDeclarations, build optimizations, and more!
Let’s look at each piece of this to go over what it does, why it is (or more often *isn’t*) needed, and why I can tell this package.json is misconfigured just from this small snippet. 🧵
That is why we all bet on
@rspack_dev
to unify compiler in bytedance,it is the only solution meets all our needs for different scenarios and scales from small apps to really huge apps.
@PatrickJS__
@QwikDev
@rspack_dev
@webpack
@mhevery
Yep! Tons of use cases for big orgs to have everyone on the same compiler. It’s one of the only ways to guarantee architectural conformance and governance. The compilation is the most critical part of the software supply chain.
Surprisingly it is the persistent cache, fast prebundle of esbuild and the lazy compilation brought by esm that make Vite perform quickly, while the bundleless brought by esm actually slows down Vite. lazy compilation, persistent cache and fast bundle are the key, not bundleless.
@rspack_dev
I really really wanted bundleless to work. Such an attractively simple solution!
We built
@nextjs
Live in part to test out this hypothesis. Everything was “browser native”, from ESM to the the runtime (WinterCG).
Then we tested it with Vercel’s homepage. 30s+ load times.
ESM is so hard and even react made mistake
thankfully we don't need to redo all the hard work and just follow webpack's behavior 🤣
I nearly learn something new about ESM every month.
The root cause is Typescript lacks single file compilation unit model(Rust seems have same problem), which limits lots of optimization, isolatedDeclarations may solve this problem so bundlers | compilers can actually do some optimization cross module boundary.
I'm wondering whether bundler & compiler should keep following Node.js new features like `module-sync`, It seems tools should be runtime agnostic, so why should we keep following Node.js specific new behavior other than Deno's or Bun's. I hope JS0 can solve these things 😅.
The abstraction of Nuxt.js on different bundlers( vite & webpack) is really great. So I only need to modify
@nuxt
/webpack-builder code and don't need to care too much about how Nuxt.js plugin works 😂
📢 Parcel v2.12.0 brings support for macros, a new web-based REPL, improved CSS bundling, and manual code splitting!
Macros are JS/TS functions that run at build time instead of being bundled. They can generate constants, code, and even assets (eg css)!
As tools and frameworks become increasingly complex and hard to debug, the next competitive focus for frameworks and tools may be devtools or called self-diagnostic capabilities.
after hours debugging a project with tons of circular dependencies, I found out a *bug* of rspack is actually user's code bug, and webpack's treeshaking remove the buggy code so it runs successfully but rspack doesn't remove the buggy code so it failed. negatives make a positive
@devongovett
@Rich_Harris
sideEffects:false does nothing _within_ modules. It's okay for passing through a barrel file, but the second that barrel file contains a side effect you're into "configure bundler to make packages not suck" territory
A bunch of awesome new features out today for Rspack v0.3.4
🍿 internal plugins support like DefinePlugin
❤️ compatible with html-webpack-plugin !
🚀 builtin:swc-loader supports builtin transformation like emotion
I understand RSC a little better now as
@ebey_jacob
made a federation POC.
“Use client” is normal ssr/csr.
RSC is “thread safe” react components. Meaning I can execute them off main thread. Be it server, web worker, or whatever.
--experimental-transform-types is really a great feature, that's the feature I want for long time. Great work by
@satanacchio
@kdy1dev
, I don't want introduce xxx-register just to support xxx.config.ts .
I originally thought it's funny name, but now I want to make it a real project. the goal becomes write a real bundler from scratch with minimal api and performance consideration and focused on the bundler architecture.
I make a repo to check different bundler behavior about circular-dependency, it turns out esbuild is the only one not following standard semantic because of the const transpiled to var which breaks TDZ, welcome more complicated cases for discussion
We are thrilled to announce that we have exceeded the 95% compatibility required by the challenge and we are continuing to improve this score! We will be submitting our solution in the coming days. Stay tuned!
I finally reproduce the treeshaking breaks TDZ case, I'm not sure whether treeshaking should keeps TDZ code, it actually bites me in real world project and I think it's the reason why people think webpack supports non-standard circular dependency.
after hours debugging a project with tons of circular dependencies, I found out a *bug* of rspack is actually user's code bug, and webpack's treeshaking remove the buggy code so it runs successfully but rspack doesn't remove the buggy code so it failed. negatives make a positive