-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(mc-scripts): manually group some vendor chunks #2998
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 59522c8 The changes in this PR will be included in the next version bump. This PR includes changesets to release 35 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Deploy preview for merchant-center-application-kit ready! ✅ Preview Built with commit 59522c8. |
9325e29
to
461f7ac
Compare
a4d36e5
to
b9caf83
Compare
b9caf83
to
dc67bff
Compare
dc67bff
to
59522c8
Compare
Branched off #2995
Extracted from #2821
To reduce the main bundle chunk even more, we can instruct the bundlers to group certain vendor packages in specific groups. As a result, the main bundle will have a smaller size. Users (via browsers) will then only need to download the smaller main bundle when it gets updated (caching) as the other vendor chunks didn't change (unless via dependency updates).
I found this article that explains well how and why it's useful like that: https://www.codemzy.com/blog/react-bundle-size-webpack-code-splitting