date-fns icon indicating copy to clipboard operation
date-fns copied to clipboard

Format returns year -1 when formatting 1st of January

Open capdavid opened this issue 3 years ago • 0 comments

Found a funny bug.. console.log(format(new Date('2022-01-01'), 'RR-MM-dd')) expected 2022-01-01

what I got 2021-01-01

Am I doing something wrong? If I am, it's very unintuitive. 😅

Thank you.

capdavid avatar Aug 11 '22 11:08 capdavid