Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect dateFormat for en-gb: (yy/mm/dd vs dd/mm/yy) #139

Closed
Petri-Oosthuizen opened this issue Nov 17, 2023 · 0 comments
Closed

Incorrect dateFormat for en-gb: (yy/mm/dd vs dd/mm/yy) #139

Petri-Oosthuizen opened this issue Nov 17, 2023 · 0 comments

Comments

@Petri-Oosthuizen
Copy link

Petri-Oosthuizen commented Nov 17, 2023

The en-gb locale file's dateFormat entry (yy/mm/dd) differs from the standard JavaScript toLocaleDateString("en-GB") method among other sources.

new Date().toLocaleDateString("en-GB") // dd/mm/yy
new Intl.DateTimeFormat("en-GB").format(new Date()) // dd/mm/yy

Other sources:
Wikipedia - Date and Time Notation in the United Kingdom
Oracle Documentation - Date and Time Formats in the United Kingdom
DateTime::Locale - DateTime::Locale::en_GB

Original PR: #65

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant