question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Replace moment.js with an alternative date library

See original GitHub issue

I noticed on Bundle Phobia that this module is just over 100kb when minified and gzipped

https://bundlephobia.com/result?p=cron@1.6.0

And the majority of the size is coming from moment.js.

As an idea and if possible it would be nice to replace moment.js with a different lighter library such as:

Has this been considered before?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:9
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
ncb000gtcommented, Apr 25, 2020

I’ve landed GH-486 which uses luxon. It hasn’t hit npm yet, as I’m going to try to roll a few changes into the next release. Sorry this has taken so long to happen and a big thanks to @bvigursky for implementing it.

2reactions
saltirecommented, Feb 13, 2019

Another option is Luxon: https://moment.github.io/luxon/

I’m sure a pull request for this issue would be welcome 😉

Read more comments on GitHub >

github_iconTop Results From Across the Web

Best Moment.js Alternatives - date-fns, Day.js, Luxon, js-joda
There are multiple solid date and time libraries for JavaScript you can use instead. We'll look into Luxon, Day.js, date-fns and js-joda. The ......
Read more >
Should You Really Switch to Day.js From Moment.js? - SoftTeco
The Day.js library is quickly becoming a number one alternative to Moment.js due to its light weight and great performance - learn more...
Read more >
The Best MomentJS Alternatives | Become Front-End Expert
Meet the most popular MomentJS alternatives. Dayjs, Date-fns and Luxon are lightweight, popular and fast libraries for handling dates.
Read more >
Life after Moment.js | 8th Light
There are several libraries out there that can potentially replace Moment in your app. The creators of Moment recommend looking into Luxon, Day....
Read more >
You don't (may not) need Moment.js - GitHub
Good library if you're looking to replace Moment.js for one reason or another. Immutable too. —Dan Abramov, Author of Redux and co-author of...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found