toLocaleDateString() - issue with Norwegian

Viewed 810

I have an issue with getting locale datestring correctly formatted. It suddenly stopped working for Norwegian. I've tried 'no-NO' and 'nb-NO'. Any ideas about what could be causing this? I'm stuck.

Example:

console.log(new Date().toLocaleDateString('no-NO', {month: 'long', day: 'numeric', year: 'numeric'}))
// 2021 M08 10

Other languages work as expected:

console.log(new Date().toLocaleDateString('da-DK', {month: 'long', day: 'numeric', year: 'numeric'}))
// 10. august 2021
1 Answers
Related