felixge/node-dateformat

Library fails for the basic case dateFormat("2022-11-10", "mmm dd")

justin-barca-at-camis opened this issue · 3 comments

Even a datestring with no time or timezone info is rendered incorrectly, date is offset.

See: https://codesandbox.io/s/naughty-lederberg-8dri33?file=/src/index.js

In the console I see "Nov 09"

Even a datestring with no time or timezone info is rendered incorrectly, date is offset.

See: https://codesandbox.io/s/naughty-lederberg-8dri33?file=/src/index.js

In the console I see "Nov 09"

I think the first input should be a date not a string. Try put a date into it. dateFormat(new Date(), "mmm dd");

Closing due to inactivity.