We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Which package? react-intl
Describe the bug not possible to use a 24 hour format with midnight as 00:00 when using locale 'en-US'
00:00
root cause: formatTime and formatDate filter out from options hourCycle
formatTime
formatDate
hourCycle
To Reproduce While using locale 'en-US' I expect to be able to pass hourCycle options to formatTime like:
const date = new Date(Date.UTC(2012, 11, 20, 0, 0, 0)); formatTime(date, {hourCycle: 'h23'})
to get 00:00
this works correctly in Intl.DateTimeFormat i.e.
Intl.DateTimeFormat
const date = new Date(Date.UTC(2012, 11, 20, 0, 0, 0)); new Intl.DateTimeFormat('en-US', {hour: '2-digit', minute: 'numeric', hourCycle: 'h23'}).format(date)
The text was updated successfully, but these errors were encountered:
Thanks for reporting! We'll take a look asap.
Sorry, something went wrong.
27d02ee
No branches or pull requests
Which package?
react-intl
Describe the bug
not possible to use a 24 hour format with midnight as
00:00
when using locale 'en-US'root cause:
formatTime
andformatDate
filter out from optionshourCycle
To Reproduce
While using locale 'en-US' I expect to be able to pass
hourCycle
options to formatTime like:to get
00:00
this works correctly in
Intl.DateTimeFormat
i.e.The text was updated successfully, but these errors were encountered: