5 ms·
I've switched most of my work that used to use moment over to Luxon[0] now. It's still written by the same authors, but fixes a lot of the drawbacks[1]. [0]: h
by wyattjoh 6y ago
I've switched most of my work that used to use moment over to Luxon[0] now. It's still written by the same authors, but fixes a lot of the drawbacks[1].
[0]: https://moment.github.io/luxon/index.html https://moment.github.io/luxon/index.html
[1]: https://moment.github.io/luxon/docs/manual/moment.html https://moment.github.io/luxon/docs/manual/moment.html
- flipchart 6y agoI'm using React Widgets[0] and I prefer moment over Globalize (been through so much pain with this). Maybe it's time to either write a localizer for Luxor or find a new date time picker [0]: https://jquense.github.io/react-widgets/localization/ https://jquense.github.io/react-widgets/localization/
- WorldMaker 6y agoDepending on your specific needs [0], a lot of date localization can be done (painfully, but possibly) directly with Browser Intl [1] calls instead of a library. [0] Current user's current locale is easy. If for some reason you need to show some other locale than what the browser is using you'll likely still need Moment or Globalize. [1] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
- WorldMaker 6y agoLuxon is great. Also, if you find you only really need one or maybe two date time utilities, date-fns [1] is an alternative that that takes an even more modular approach for tinier imports. [1] https://date-fns.org/ https://date-fns.org/