-
Notifications
You must be signed in to change notification settings - Fork 247
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
[v2] build size is too large #328
Comments
Really wondering how object spread/object assign already causes trouble/issues there. The current workaround is decent but I'd suggest finding the root cause in a future version so we can keep using new features in the code |
What I did was remove babel, add buble, imported a import 'core-js/modules/es6.array.includes' Thats where the 4KB came from, without the single polyfill it was 10KB, with 14+KB I also simply checked babel's polyfilled 30KB gzipped lib to see what was in it. Eg it also contained quite a bit of stuff about regexes, probably because the polyfills not only enable features but also fix wrong behaviour without checking whether the exact cases where that wrong behaviour is triggered are at all used in the source. The only regexes which we use are in eg Could very well be that I am wrong in my observations, but for now I will leave this issue as is. Also please note that this has never been an issue before due to the major difference between buble and babel. For good comparison we should probably take the current v1 codebase and see what babel tries to polyfill, I will leave that to you if you think thats interesting ;) |
When working on v2.0 I was advised to follow the doctrine of letting the transpiler worry about language features, but it seems this resulted in a hugh increase in package size. Current v2 minified size is ~30KB
Possible solutions:
The text was updated successfully, but these errors were encountered: