Skip to content

refactor(Style): replace default export with named #4064

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

grigoriy-reshetniak
Copy link
Contributor

This PR is done in assumption, that only some files require all for exported Style types and for most of them only subset they use would be sufficient, and unused instances wouldn't be imported, reducing bundle size. It is indeed slightly smaller, from 608.07 KB to 607.53 KB based on yarn analyze (parsed).

I feel like maybe if this done at the scale it could reduce bundle more significantly, but I'm interested in maintainers opinion about this, is it worth checking all default exports or do you prefer them over the named?

What is the previous behavior before this PR?
export default was used

What is the new behavior after this PR?
export const is used now

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

Successfully merging this pull request may close these issues.

1 participant