Slow load times caused by React


#1

Our site has slowed down recently and I’ve been digging into the Chrome dev tools to try and find the issue. One item I just noticed was that when the homepage is first loaded, our React routes on the site are being loaded and taking about 500ms of Javascript scripting time to complete.

This is one of many issues, but I’m not sure why it’s taking hundreds of milliseconds to load the JS on the page when none of it is needed for the homepage.

Below is a screenshot of what we’re seeing. Our app is a mix of Blaze and React and we don’t even have that many React routes at the moment, but it’s still taking 361ms to load up. I imagine the problem will only get worse as we add more React routes. Has anyone had a similar experience and is there something that can be done to fix this?