DEV Community

Discussion on: Lightning fast & simple Typescript Serverless builds

Collapse
tastefulelk profile image
Sebastian Bille Author

Hi Muhammad! The image I shared is from the benchmarks you can find in the link below. I haven't done any further performacne testing on esbuild vs webpack for bundling a serverless project but there's essentially no difference, this is just a way to plug the bundler into the deployment flow of Serverless Framework!

esbuild.github.io/faq/#benchmark-d...

Collapse
hasnaindev profile image
Muhammad Hasnain

Thanks. I was about to ask if esbuild supports code-splitting, HMR, front-end libraries support and other tools we're used to. Their roadmap has more detail on it but they aren't planning on adding those things except for code-splitting.

I'm pretty sure this tool might be have it's applications, albeit, somewhat rare or exceptional.

Thread Thread
astuyve profile image
AJ Stuyvenberg

HMR and front-end libs aren't generally needed for the purposes of the Serverless Framework and therefore this post.

But certainly worthwhile in the broader scheme of things. ES Build isn't a direct replacement for webpack generally, but in most serverless cases - it is.

Thread Thread
hasnaindev profile image
Muhammad Hasnain • Edited on

I agree. For these reasons, I don't think a esbuild's official comparison, such as above is meaningful.

Thread Thread
memark profile image
Magnus Markling

@hasnaindev you might want to look into the tool "Vite" if you're more interested in esbuild in a front-end context.