3cn-ecn/nantralPlatform

Replace Webpack with Esbuild and eventually Vite

Closed this issue · 3 comments

Capture

Use esbuild instead of Webpack to improve build times.

I don't know at all esbuild, are our dependencies all compatible with it? For example we started to use mui for the frontend, but their documentation only says how to configure it with webpack

Module bundlers do not have compatibility issues with NPM packages, only runtimes (the config differs between a Node.js runtime and a Browser runtime for example).

After some testing, I could not find any error with the scripts bundled with ESBuild.

I have merged the changes in staging with #749.

Here is a preview of the performances benefits during the build on my machine:

WEBPACK
webpack
ESBUILD
esbuild

The performance gains allowed me to switch the build from Github back to our VPS.

The performance gains allowed me to switch the build from Github back to our VPS.

Nevermind: 9345692