Javscript bundles are full of duplicate packages #15207
Labels
status: awaiting author response
Additional information has been requested from the author
type: question or discussion
Issue discussing or asking a question about Gatsby
Description
I have noticed some fairly large Javascript files on my site. Most of them in the range 100-400KB. Examination with
source-map-explorer
showed that most of the size of them consists of duplicate libraries. I'm aware that Gatsby bundles packages that are used multiple times in thecommons-*.js
file. But for some reason, my build does not seem to make one. I know I've seen it be created before, but now my build only containscomponent-*.js
files. I cannot place how or when thecommons-*.js
is created and would like some guidance in understanding when it happens? And will the bundling occur the same duringdevelop
andbuild
commands?Steps to reproduce
Unfortunately I have not identified how to reproduce
Expected result
There should always be a bundled
commons-*.js
file createdActual result
commons-*.js
bundle is not always created, even when the build will greatly benefit from itEnvironment
The text was updated successfully, but these errors were encountered: