Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[Wallet] Use esm version of date-fns #6994

Merged
merged 2 commits into from
Feb 9, 2021
Merged

[Wallet] Use esm version of date-fns #6994

merged 2 commits into from
Feb 9, 2021

Conversation

gnardini
Copy link
Contributor

@gnardini gnardini commented Feb 9, 2021

Description

We were importing the format method from date-fns which made it so the whole date-fns library was included in the bundle. Replaced with an import from date-fns/esm/format which includes only the necessary stuff and reduces the size on the bundle from ~185kb to ~24kb

Other changes

N/A

Tested

N/A

Related issues

Backwards compatibility

N/A

@gnardini gnardini added the wallet label Feb 9, 2021
@gnardini gnardini requested a review from a team February 9, 2021 14:32
Copy link
Contributor

@jeanregisser jeanregisser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 🚀

@gnardini gnardini added the automerge Have PR merge automatically when checks pass label Feb 9, 2021
@mergify mergify bot merged commit 3e165ab into master Feb 9, 2021
@mergify mergify bot deleted the date-fns-esm branch February 9, 2021 16:58
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
automerge Have PR merge automatically when checks pass wallet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Import only the used methods from date-fns
2 participants