Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Really hope this gets a competent library mode. Webpacks library mode never really evolved to meet the needs of things. Vite has a good library mode but it has its own limitations.

Pure rollup is still the best for building libraries, by and large (maybe esbuild now? but I think rollup is more efficient in its output still).

If this has a good, solid library mode that works like rollup with the power of the webpack-like asset graph, it'd actually be amazing for the community as a whole.



Yes. I mostly build libraries and rollup still beats everything in compatibility (esm, umd, cjs, etc) and output quality. It's slow, though, and I would love a faster alternative. Esbuild doesn't do tree shaking as well as rollup.


Vite uses it under the hood and has it running crazy fast.


I think Vite only uses it for the production build, no? As far as I know Vite doesn't do bundling (yet) in dev mode.


Vite uses both esbuild and rollup for the prod build. When doing React, it also adds Babel. This chaining of tools is the reason why it's so slow.


"so slow." JS-perf world is quite insufferable. We're talking 0.09s vs 0.01s https://mobile.twitter.com/youyuxi/status/158506616237077709...


Can esbuild support esm or umd etc via plugins? I've looked at using it but these formats are an unfortunate requirement for the builds I need to do.

I noted that esbuild doesn't fully support es5 transpilation and this will hold it back from some usage.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: