The Temporal API is now available in Deno. Given this library's popularity in the Deno ecosystem, I think it would make sense to support passing Temporal.Instant objects the same way we can currently pass Date objects.
You can easily convert a Temporal.Instant to a Date like so:
// From the Temporal cookbook: https://tc39.es/proposal-temporal/docs/instant.html#interoperability-with-date
instant = Temporal.Instant.from('2020-01-01T00:00:00.123456789+05:30');
// => 2019-12-31T18:30:00.123456789Z
date = new Date(instant.epochMilliseconds);
Supporting the more advanced Temporal types, like Temporal.ZonedDateTime for Timestamptzs or Temporal.Duration for Intervals, could also be an interesting thing to pursue in the future.
The Temporal API is now available in Deno. Given this library's popularity in the Deno ecosystem, I think it would make sense to support passing
Temporal.Instant
objects the same way we can currently pass Date objects.You can easily convert a
Temporal.Instant
to aDate
like so:Supporting the more advanced
Temporal
types, likeTemporal.ZonedDateTime
forTimestamptz
s orTemporal.Duration
forInterval
s, could also be an interesting thing to pursue in the future.