Skip to content
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

Replace moment.js #2

Closed
ngehlert opened this issue May 5, 2019 · 4 comments
Closed

Replace moment.js #2

ngehlert opened this issue May 5, 2019 · 4 comments

Comments

@ngehlert
Copy link

ngehlert commented May 5, 2019

Are you willing to accept a PR to remove moment() as dependency and use something more lightweigt?

Or instead a PR to at least only import the needed functions from moment instead of the entire lib?

@jonsamp
Copy link
Owner

jonsamp commented May 10, 2019

Yes, this is a great improvement idea and one im working on right now. I'm going to convert this lib to use date-fns. If you have another lib in mind, let me know. But this one seems popular and vastly smaller and faster than moment.

@ngehlert
Copy link
Author

sounds awesome. yes I would've chosen date-fns as well. let me know if you need any help :)

@jonsamp
Copy link
Owner

jonsamp commented May 11, 2019

I just published a new version that replaces moment with date-fns 🎉

You can see the entire PR here if you're interested: #4

Also, here's a graph showing the size decrease after conversion. Great improvement!
Screen Shot 2019-05-10 at 9 44 50 PM

... Now on to adding a an index.d.ts

@jonsamp jonsamp closed this as completed May 11, 2019
@ngehlert
Copy link
Author

you are awesome. thanks for your work

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

No branches or pull requests

2 participants