You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With these helpers on JS (browsers, node.js), we obtain an OffsetDateTime.now() equivalent (of course up to millisecond resolution due to JS nature) without the need to add tzdb. This unlocks all of {LocalDate, LocalDateTime, LocalTime, MonthDay, OffsetDateTime, OffsetTime, Year, YearMonth}.now() straightforward implementations in terms of the OffsetDateTime.now() instance. And only ZonedDateTime, which intuitively should be the only one that requires actual tz data is left with that need.
The text was updated successfully, but these errors were encountered:
gatisnolv
changed the title
Proposal for JS for implementing .now() without tzdb for all classes except for ZonedDateTime
Proposal for JS for implementing .now() without tzdb for all "time" classes except for ZonedDateTime
Nov 10, 2023
With these helpers on JS (browsers, node.js), we obtain an OffsetDateTime.now() equivalent (of course up to millisecond resolution due to JS nature) without the need to add tzdb. This unlocks all of {LocalDate, LocalDateTime, LocalTime, MonthDay, OffsetDateTime, OffsetTime, Year, YearMonth}.now() straightforward implementations in terms of the OffsetDateTime.now() instance. And only ZonedDateTime, which intuitively should be the only one that requires actual tz data is left with that need.
What do you think about this?
The text was updated successfully, but these errors were encountered: