-
Notifications
You must be signed in to change notification settings - Fork 99
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
[2.0.0-beta.3] Build is almost 50% bigger than with version 1.5.0 #461
Comments
My immediate guess is that this is tied to the helpers that Babel 7 emits for each module with decorators and the like being more verbose than they were in previous versions. The raw growth (38.6%) vs gzipped growth (16.9%) also points that direction (or at least an increase in repeated content in the output). This is likely to come up across the broader Ember ecosystem as more folks upgrade to Babel 7 and as decorators become part of the core programming model for Ember. A while back @pzuraq was investigating ways to have Babel use shared importable versions of these helpers rather than emitting them separately for each module, but I don't know that anyone is actively working on that at the moment. |
Got diverted from working on this, but should be back on it in the coming weeks! |
So does this mean that this is going to be resolved as an issue at some point? And do you think it's OK to downgrade |
I’ll see if I can handle it this week. It’ll definitely be handled in the coming months, for sure |
@boris-petrov so for what it's worth, we're upgrading ember-cli-typescript for better maintainability and integration with the ecosystem (especially things like ember-auto-import), but the current experience is quite solid in general. Hopefully we and @pzuraq can help Babel iterate on this to get it sorted sooner rather than later, but you should be just fine on the 1.x series. |
Thank you all for the support! Let's hope that you can resolve the problem for everybody. :) |
Work on externalized helpers: emberjs/ember-cli-babel#251 |
@boris-petrov, ember-cli-babel 7.3.0-beta.1 should solve this. You will need to enable the new |
@jamescdavis - thanks! I'll be sure to try that some time next week. Will report back. :) |
@jamescdavis - I updated
Should I have done something else? One thing that I noticed is that |
@boris-petrov can you file a proper bug report including your
We have an issue template for build-related bugs to help gather information to reproduce these kinds of things. |
OK, so the error above was because of this Babel issue so no need to open a new bug report here. With that fixed on my side, our build is now |
I think all is fine on our side - tests are passing and all seems to work. Just a quick question before I close this - why is this still generating slightly bigger code than TypeScript? What is the difference now that all helpers are deduplicated? |
There are two reasons that the code may be slightly bigger:
|
@pzuraq - thank you for the detailed explanation and for the great work on this! |
We just noticed that a single commit of ours which updates
ember-cli-babel
from6.17.2
to7.1.3
,ember-cli-typescript
from1.5.0
to2.0.0-beta.3
andember-auto-import
from1.2.15
to1.2.17
caused our production ES6 build to grow from822.66 KB (130.52 KB gzipped)
to1.14 MB (152.94 KB gzipped)
. Not sure where the problem is but this is pretty major so I wanted to ask here for any ideas. How do we debug this? I'm willing to help with whatever I can.P.S. This is our
frontend.js
file, notvendor.js
.The text was updated successfully, but these errors were encountered: