News for hackers. Stuff that matters.
Re:Day.js Fast 2kB alternative to Moment.js with the same mo... by laundermaf on Sunday October 09, 2022 @04:02AM (#33138998)
I think you’re missing the point entirely. If Date has a method that does what you need, by all means use it directly.

Libraries come in handy when doing things that aren’t one liners.

A colleague thought it was super easy to change that exact ISO string to use the local timezone instead of UTC, against my advice. Guess what. The minus sign broke it and he would have never known because most customers are in the US, then they travel to Singapore and your product is worthless. By the time you hear about it, you lost the customer’s money and time therefore you lost the customer.

Moment and Luxon are too heavy, I agree, but date-fns isn’t.

There are no comments on this comment yet.