Closed justingrant closed 7 months ago
The docs say that the calendar and timeZone arguments to Temporal constructors must be an object. Example:
calendar
timeZone
timeZone (Temporal.TimeZone or plain object): The time zone in which the event takes place. calendar (optional Temporal.Calendar or plain object): Calendar used to interpret dates and times. Usually set to 'iso8601'.
Temporal.TimeZone
Temporal.Calendar
'iso8601'
But the spec and the polyfill can also accept a string. Repro:
new Temporal.PlainDate(2000, 1, 1, 'chinese'); // => 2000-01-01[u-ca-chinese]
I assume the spec and polyfill are correct and the docs are wrong. True?
Yes, this should be updated in the documentation.
This has been fixed in the meantime.
The docs say that the
calendar
andtimeZone
arguments to Temporal constructors must be an object. Example:But the spec and the polyfill can also accept a string. Repro:
I assume the spec and polyfill are correct and the docs are wrong. True?