Skip to content
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

Bundle size regression in v6.2.0 #1800

Closed
jelhan opened this issue Nov 12, 2023 · 3 comments
Closed

Bundle size regression in v6.2.0 #1800

jelhan opened this issue Nov 12, 2023 · 3 comments

Comments

@jelhan
Copy link
Contributor

jelhan commented Nov 12, 2023

v6.2.0 seem to dramatically increase the bundle size of a consuming application.

I noticed it by an app, which uses ember-cli-bundlesize in CI pipeline. The bundle size test started failed in the upgrade from 6.1.2 to 6.2.0:

> ember bundlesize:test

Building for production...
not ok 1 - app:javascript: 329.21KB > 310KB (gzip)
ok 2 - app:css: 16.09KB <= 16.5KB (gzip)
Bundlesize check failed with 1 error!

App JavaScript was 306KB in a recent pipeline for main branch. Seems that ember-intl v6.2.0 increases it by more than 23KB.

The affected app is open source. Please find the PR upgrading ember-intl from 6.1.2 to 6.2.0 here: jelhan/croodle#758

@ijlee2
Copy link
Collaborator

ijlee2 commented Nov 13, 2023

@jelhan Thanks for reporting the rather large increase in bundle size. I'm surprised because I removed two dependencies in 6.2.0, and npm shows a decrease in the number of files and in the unpacked size by 5kB.

I can think of a couple of possibilities:

The latter has to do with test helpers, which shouldn't affect the production build. To check the former, can you use npm overrides to pin the ember-intl's dependencies to the latest version?

(@formatjs/intl showed a difference in unpacked size between 2.9.6 and 2.9.8, but their release notes didn't clearly indicate what changed. intl-messageformat showed an even larger difference between 10.5.5 and 10.5.7.)

@ijlee2
Copy link
Collaborator

ijlee2 commented Nov 17, 2023

Hi, @jelhan. Have you had a chance to look at updating @formatjs/* and intl-messageformat to the latest, to see if this reduces the bundle size?

Update: Please try updating ember-intl to v6.2.2.

@jelhan
Copy link
Contributor Author

jelhan commented Nov 25, 2023

Please try updating ember-intl to v6.2.2.

v6.2.2 fixed it. CI passed, which failed for bundle size check before. Thanks a lot for fixing!

@jelhan jelhan closed this as completed Nov 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants