We're using create-react-app
(with react-app-rewired
) on a very large monolith. We've done some improvements to the build time (got it down to approx 20s), but after the build is complete (following a yarn start
) the application takes a good 2 minutes to actually load on the browser.
In app.jsx
I've tried removing all the root code and just rendered a typical "Hello World" p
tag and it doesn't take nearly as long. I've also ran a basic web server infront of the build folder using serve which suggests it might webpack-dev-server
that is having issues with the size of the application (Or could it be saying it's built before it actually is?).
In the chrome dev tools network tab the assets that are blocking the page from loading are the files from the static
/js
folder.
Here is a gist of the result from webpack-bundle-analyzer
Does anyone have any ideas where this issue could be originating and how to improve post-build load time?