I’ve updated an Angular 17 project to the new Vite + ESBuild build system, and noticed that the bundle size increased:
WebPack Build:
ESBuild + Vite Build:
The new Vite + ESBuild version built the project faster than Webpack, which isn’t a surprise. But what I didn’t expect was the initial bundle size to increase so much (2.01Mb to 2.24Mb).
I followed Angular’s official docs to update the project.
Besides the build speed, aren’t the bundle sizes suppose to decrease with ESBuild? Am I missing any extra configurations that would help reduce the initial bundle?