4 ms·
the benefits of esm are not compelling enough to rewrite everything. Browser-native module loading is a niche use case which can never be as performant as bundl
by jhp123 3y ago
the benefits of esm are not compelling enough to rewrite everything. Browser-native module loading is a niche use case which can never be as performant as bundling (even if per-request overhead is minimized in http2, a chain of dependencies will lead to excess round trips).
- cxr 3y ago> the benefits of esm are not compelling enough to rewrite everything. Your "everything" somehow doesn't account for stuff that wasn't written in NodeJS's standards-incompatible way to begin with.
- lelanthran 3y ago> the benefits of esm are not compelling enough to rewrite everything. It's rare that standards don't beat out non-standards in adoption. ESM is the standard; there is only one way this ends,and it's not in favour of CJS.
- klodolph 3y agoBundling works better with ES6 modules. Compare the experience of using, say, browserify to rollup/esbuild. Plus, with ES6 modules, you can do bundling for your release builds, and do your development work directly with the original source files.