-
Notifications
You must be signed in to change notification settings - Fork 94
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
Reduce bundle size #88
Comments
moving from const to let can also save some bytes, if you agree) |
Did you measure the reductions after transpiling the code? |
That's fun, for current rollup setup build size increases for all 3 of bundles (cjs, default and minified), as it builds to ES5. So the question now is should we optimize for older or for newer browsers. Decision is for you :) |
Some more info - when I build the project as is, the minified file size is 6312b. When I add optimizations, file size grows to 6459b, but if I add a browserslist config with (for example) Also this optimizations will be used by a large number of developers, who build |
Hello! I saw that you race for minified size, and I have tried several options to minify the bunde for modern browsers for about 15%:
let x = true
and set all settings fromcontextTypes: true
tocontextTypes: x
- saves ~20b of minified codegetStatics
method to arrow function - 16b of minified codeUnminified souce is also reduced by 400 bytes
Should I provide a PR for all of this or some points are useless?)
The text was updated successfully, but these errors were encountered: