Skip to content

How to format a CalendarDate #5811

Answered by snowystinger
smozely asked this question in Q&A
Discussion options

You must be logged in to vote

You are handling it how we would expect.
The formatter can omit the time and timezone, however, a time component is necessary in the construction because you may be rendering the same date object in multiple timezones which may affect the actual date in that timezone or even in another calendar system.
Whether you specify a time with a Date object or not, it always has one https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date#date_components_and_time_zones

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@smozely
Comment options

@snowystinger
Comment options

@smozely
Comment options

@devongovett
Comment options

Answer selected by smozely
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants