telekom-mms/aurelia-components

Replace momentjs

Closed this issue · 2 comments

Momentjs is sunsetting. These are the alternatives: https://github.com/you-dont-need/You-Dont-Need-Momentjs/blob/master/README.md

My favourite: day-fns

Zsar commented

Mmh. Unsure. I'd rather wait for Intl. What we can do, however, is to change the current moment.js code such as to make it an optionalPeerDependency and offer alternatives, e.g. via day-fns. Even if Intl would satisfy all use cases of a library consumer, they might prefer to stick to the one library they are already using.

... We will have to be careful not to turn this into feature creep though. "If we support bindings for two (later three) libraries, why not for four?", etc. My hope is to deprecate the moment.js stuff in favour of Intl and completely drop third-party library support... have not researched enough to understand how un-/realistic that might be, though.

Zsar commented

... That said, if you'd like to add day-fns components/elements, I would not object. As you noticed, I do not really find the time to participate here as much as I should (and e.g. do said research to actually obtain an informed opinion).
I'd be fine with adding stuff temporarily and later back-pedalling towards pure Intl support (insofar as viable).