Uncategorized
function Temporal.Now.instant
function Temporal.Now.plainDateISO
plainDateISO(timeZone?: TimeZoneLike): PlainDateParameters
timeZone: TimeZoneLike optional
Return Type
function Temporal.Now.plainDateTimeISO
plainDateTimeISO(timeZone?: TimeZoneLike): PlainDateTimeParameters
timeZone: TimeZoneLike optional
Return Type
function Temporal.Now.plainTimeISO
plainTimeISO(timeZone?: TimeZoneLike): PlainTimeParameters
timeZone: TimeZoneLike optional
Return Type
function Temporal.Now.timeZoneId
timeZoneId(): stringReturn Type
string function Temporal.Now.zonedDateTimeISO
zonedDateTimeISO(timeZone?: TimeZoneLike): ZonedDateTimeParameters
timeZone: TimeZoneLike optional
Return Type
interface Temporal.DateTimeLikeObject
interface Temporal.DisambiguationOptions
Properties
disambiguation:
"compatible"
| "earlier"
| "later"
| "reject"
| undefined
optional
interface Temporal.Duration
Properties
years: number readonly
months: number readonly
weeks: number readonly
days: number readonly
hours: number readonly
minutes: number readonly
seconds: number readonly
milliseconds: number readonly
microseconds: number readonly
nanoseconds: number readonly
sign: number readonly
blank: boolean readonly
[[Symbol.toStringTag]]: "Temporal.Duration" readonly
Methods
with(durationLike: PartialTemporalLike<DurationLikeObject>): Duration add(other: DurationLike): Duration subtract(other: DurationLike): Duration round(roundTo: PluralizeUnit<"day" | TimeUnit>): Duration round(roundTo: DurationRoundingOptions): Duration total(totalOf: PluralizeUnit<"day" | TimeUnit>): number total(totalOf: DurationTotalOptions): number toString(options?: DurationToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DurationFormatOptions,
): string toJSON(): string valueOf(): never variable Temporal.Duration
Type
interface Temporal.DurationConstructor
Properties
Methods
from(item: DurationLike): Duration compare(): number interface Temporal.DurationLikeObject
Properties
years: number | undefined optional
months: number | undefined optional
weeks: number | undefined optional
days: number | undefined optional
hours: number | undefined optional
minutes: number | undefined optional
seconds: number | undefined optional
milliseconds: number | undefined optional
microseconds: number | undefined optional
nanoseconds: number | undefined optional
interface Temporal.DurationRelativeToOptions
Properties
relativeTo: optional
interface Temporal.DurationToStringOptions
extends ToStringRoundingOptionsWithFractionalSeconds<Exclude<TimeUnit, "hour" | "minute">>
interface Temporal.Instant
Properties
epochMilliseconds: number readonly
epochNanoseconds: bigint readonly
[[Symbol.toStringTag]]: "Temporal.Instant" readonly
Methods
add(duration: DurationLike): Instant subtract(duration: DurationLike): Instant until(
other: InstantLike,
options?: RoundingOptionsWithLargestUnit<TimeUnit>,
): Duration since(
other: InstantLike,
options?: RoundingOptionsWithLargestUnit<TimeUnit>,
): Duration round(roundTo: PluralizeUnit<TimeUnit>): Instant round(roundTo: RoundingOptions<TimeUnit>): Instant equals(other: InstantLike): boolean toString(options?: InstantToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never toZonedDateTimeISO(timeZone: TimeZoneLike): ZonedDateTime variable Temporal.Instant
Type
interface Temporal.InstantConstructor
Properties
Methods
from(item: InstantLike): Instant fromEpochMilliseconds(epochMilliseconds: number): Instant fromEpochNanoseconds(epochNanoseconds: bigint): Instant compare(
one: InstantLike,
two: InstantLike,
): number interface Temporal.InstantToStringOptions
extends PlainTimeToStringOptions
Properties
timeZone: TimeZoneLike | undefined optional
interface Temporal.OverflowOptions
Properties
overflow:
"constrain"
| "reject"
| undefined
optional
interface Temporal.PlainDate
Properties
calendarId: string readonly
era: string | undefined readonly
eraYear: number | undefined readonly
year: number readonly
month: number readonly
monthCode: string readonly
day: number readonly
dayOfWeek: number readonly
dayOfYear: number readonly
weekOfYear: number | undefined readonly
yearOfWeek: number | undefined readonly
daysInWeek: number readonly
daysInMonth: number readonly
daysInYear: number readonly
monthsInYear: number readonly
inLeapYear: boolean readonly
[[Symbol.toStringTag]]: "Temporal.PlainDate" readonly
Methods
add(
duration: DurationLike,
options?: OverflowOptions,
): PlainDate subtract(
duration: DurationLike,
options?: OverflowOptions,
): PlainDate with(
dateLike: PartialTemporalLike<DateLikeObject>,
options?: OverflowOptions,
): PlainDate withCalendar(calendarLike: CalendarLike): PlainDate until(
other: PlainDateLike,
options?: RoundingOptionsWithLargestUnit<DateUnit>,
): Duration since(
other: PlainDateLike,
options?: RoundingOptionsWithLargestUnit<DateUnit>,
): Duration equals(other: PlainDateLike): boolean toPlainDateTime(time?: PlainTimeLike): PlainDateTime toZonedDateTime(timeZone: TimeZoneLike): ZonedDateTime toString(options?: PlainDateToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never variable Temporal.PlainDate
Type
interface Temporal.PlainDateConstructor
Properties
Methods
from(
item: PlainDateLike,
options?: OverflowOptions,
): PlainDate compare(
one: PlainDateLike,
two: PlainDateLike,
): number interface Temporal.PlainDateTime
Properties
calendarId: string readonly
era: string | undefined readonly
eraYear: number | undefined readonly
year: number readonly
month: number readonly
monthCode: string readonly
day: number readonly
hour: number readonly
minute: number readonly
second: number readonly
millisecond: number readonly
microsecond: number readonly
nanosecond: number readonly
dayOfWeek: number readonly
dayOfYear: number readonly
weekOfYear: number | undefined readonly
yearOfWeek: number | undefined readonly
daysInWeek: number readonly
daysInMonth: number readonly
daysInYear: number readonly
monthsInYear: number readonly
inLeapYear: boolean readonly
[[Symbol.toStringTag]]: "Temporal.PlainDateTime" readonly
Methods
with(
dateTimeLike: PartialTemporalLike<DateTimeLikeObject>,
options?: OverflowOptions,
): PlainDateTime withPlainTime(plainTime?: PlainTimeLike): PlainDateTime withCalendar(calendar: CalendarLike): PlainDateTime add(
duration: DurationLike,
options?: OverflowOptions,
): PlainDateTime subtract(
duration: DurationLike,
options?: OverflowOptions,
): PlainDateTime until(
other: PlainDateTimeLike,
options?: RoundingOptionsWithLargestUnit<DateUnit | TimeUnit>,
): Duration since(
other: PlainDateTimeLike,
options?: RoundingOptionsWithLargestUnit<DateUnit | TimeUnit>,
): Duration round(roundTo: PluralizeUnit<"day" | TimeUnit>): PlainDateTime round(roundTo: RoundingOptions<"day" | TimeUnit>): PlainDateTime equals(other: PlainDateTimeLike): boolean toString(options?: PlainDateTimeToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never toZonedDateTime(
timeZone: TimeZoneLike,
options?: DisambiguationOptions,
): ZonedDateTime variable Temporal.PlainDateTime
interface Temporal.PlainDateTimeConstructor
Properties
prototype: PlainDateTime readonly
Methods
from(
item: PlainDateTimeLike,
options?: OverflowOptions,
): PlainDateTime compare(
one: PlainDateTimeLike,
two: PlainDateTimeLike,
): number interface Temporal.PlainDateToStringOptions
Properties
calendarName:
"auto"
| "always"
| "never"
| "critical"
| undefined
optional
interface Temporal.PlainDateToZonedDateTimeOptions
Properties
plainTime: PlainTimeLike | undefined optional
interface Temporal.PlainMonthDay
Properties
calendarId: string readonly
monthCode: string readonly
day: number readonly
[[Symbol.toStringTag]]: "Temporal.PlainMonthDay" readonly
Methods
with(
monthDayLike: PartialTemporalLike<DateLikeObject>,
options?: OverflowOptions,
): PlainMonthDay equals(other: PlainMonthDayLike): boolean toString(options?: PlainDateToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never variable Temporal.PlainMonthDay
interface Temporal.PlainMonthDayConstructor
Properties
prototype: PlainMonthDay readonly
Methods
from(
item: PlainMonthDayLike,
options?: OverflowOptions,
): PlainMonthDay interface Temporal.PlainMonthDayToPlainDateOptions
interface Temporal.PlainTime
Properties
hour: number readonly
minute: number readonly
second: number readonly
millisecond: number readonly
microsecond: number readonly
nanosecond: number readonly
[[Symbol.toStringTag]]: "Temporal.PlainTime" readonly
Methods
add(duration: DurationLike): PlainTime subtract(duration: DurationLike): PlainTime with(
timeLike: PartialTemporalLike<TimeLikeObject>,
options?: OverflowOptions,
): PlainTime until(
other: PlainTimeLike,
options?: RoundingOptionsWithLargestUnit<TimeUnit>,
): Duration since(
other: PlainTimeLike,
options?: RoundingOptionsWithLargestUnit<TimeUnit>,
): Duration equals(other: PlainTimeLike): boolean round(roundTo: PluralizeUnit<TimeUnit>): PlainTime round(roundTo: RoundingOptions<TimeUnit>): PlainTime toString(options?: PlainTimeToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never variable Temporal.PlainTime
Type
interface Temporal.PlainTimeConstructor
Properties
Methods
from(
item: PlainTimeLike,
options?: OverflowOptions,
): PlainTime compare(
one: PlainTimeLike,
two: PlainTimeLike,
): number interface Temporal.PlainTimeToStringOptions
extends ToStringRoundingOptionsWithFractionalSeconds<Exclude<TimeUnit, "hour">>
interface Temporal.PlainYearMonth
Properties
calendarId: string readonly
era: string | undefined readonly
eraYear: number | undefined readonly
year: number readonly
month: number readonly
monthCode: string readonly
daysInYear: number readonly
daysInMonth: number readonly
monthsInYear: number readonly
inLeapYear: boolean readonly
[[Symbol.toStringTag]]: "Temporal.PlainYearMonth" readonly
Methods
with(
yearMonthLike: PartialTemporalLike<YearMonthLikeObject>,
options?: OverflowOptions,
): PlainYearMonth add(
duration: DurationLike,
options?: OverflowOptions,
): PlainYearMonth subtract(
duration: DurationLike,
options?: OverflowOptions,
): PlainYearMonth until(
other: PlainYearMonthLike,
options?: RoundingOptionsWithLargestUnit<"year" | "month">,
): Duration since(
other: PlainYearMonthLike,
options?: RoundingOptionsWithLargestUnit<"year" | "month">,
): Duration equals(other: PlainYearMonthLike): boolean toString(options?: PlainDateToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never variable Temporal.PlainYearMonth
interface Temporal.PlainYearMonthConstructor
Properties
prototype: PlainYearMonth readonly
Methods
from(
item: PlainYearMonthLike,
options?: OverflowOptions,
): PlainYearMonth compare(
one: PlainYearMonthLike,
two: PlainYearMonthLike,
): number interface Temporal.PlainYearMonthToPlainDateOptions
Properties
day: number interface Temporal.RoundingOptions
Type Parameters
Properties
smallestUnit: PluralizeUnit<Units> | undefined optional
roundingIncrement: number | undefined optional
roundingMode:
"ceil"
| "floor"
| "expand"
| "trunc"
| "halfCeil"
| "halfFloor"
| "halfExpand"
| "halfTrunc"
| "halfEven"
| undefined
optional
interface Temporal.RoundingOptionsWithLargestUnit
extends RoundingOptions<Units>
Type Parameters
Properties
largestUnit: optional
interface Temporal.TimeLikeObject
Properties
hour: number | undefined optional
minute: number | undefined optional
second: number | undefined optional
millisecond: number | undefined optional
microsecond: number | undefined optional
nanosecond: number | undefined optional
interface Temporal.ToStringRoundingOptions
extends Pick<RoundingOptions<Units>, "smallestUnit" | "roundingMode">
interface Temporal.ToStringRoundingOptionsWithFractionalSeconds
extends ToStringRoundingOptions<Units>
Type Parameters
Properties
fractionalSecondDigits:
"auto"
| 0
| 1
| 2
| 3
| 4
| 5
| 6
| 7
| 8
| 9
| undefined
optional
interface Temporal.TransitionOptions
Properties
direction: "next" | "previous" interface Temporal.YearMonthLikeObject
extends Omit<DateLikeObject, "day">
interface Temporal.ZonedDateTime
Properties
calendarId: string readonly
timeZoneId: string readonly
era: string | undefined readonly
eraYear: number | undefined readonly
year: number readonly
month: number readonly
monthCode: string readonly
day: number readonly
hour: number readonly
minute: number readonly
second: number readonly
millisecond: number readonly
microsecond: number readonly
nanosecond: number readonly
epochMilliseconds: number readonly
epochNanoseconds: bigint readonly
dayOfWeek: number readonly
dayOfYear: number readonly
weekOfYear: number | undefined readonly
yearOfWeek: number | undefined readonly
hoursInDay: number readonly
daysInWeek: number readonly
daysInMonth: number readonly
daysInYear: number readonly
monthsInYear: number readonly
inLeapYear: boolean readonly
offsetNanoseconds: number readonly
offset: string readonly
[[Symbol.toStringTag]]: "Temporal.ZonedDateTime" readonly
Methods
with(
zonedDateTimeLike: PartialTemporalLike<ZonedDateTimeLikeObject>,
options?: ZonedDateTimeFromOptions,
): ZonedDateTime withPlainTime(plainTime?: PlainTimeLike): ZonedDateTime withTimeZone(timeZone: TimeZoneLike): ZonedDateTime withCalendar(calendar: CalendarLike): ZonedDateTime add(
duration: DurationLike,
options?: OverflowOptions,
): ZonedDateTime subtract(
duration: DurationLike,
options?: OverflowOptions,
): ZonedDateTime until(
other: ZonedDateTimeLike,
options?: RoundingOptionsWithLargestUnit<DateUnit | TimeUnit>,
): Duration since(
other: ZonedDateTimeLike,
options?: RoundingOptionsWithLargestUnit<DateUnit | TimeUnit>,
): Duration round(roundTo: PluralizeUnit<"day" | TimeUnit>): ZonedDateTime round(roundTo: RoundingOptions<"day" | TimeUnit>): ZonedDateTime equals(other: ZonedDateTimeLike): boolean toString(options?: ZonedDateTimeToStringOptions): string toLocaleString(
locales?: Intl.LocalesArgument,
options?: Intl.DateTimeFormatOptions,
): string toJSON(): string valueOf(): never getTimeZoneTransition(direction: "next" | "previous"): ZonedDateTime | null getTimeZoneTransition(direction: TransitionOptions): ZonedDateTime | null variable Temporal.ZonedDateTime
interface Temporal.ZonedDateTimeConstructor
Properties
prototype: ZonedDateTime readonly
Methods
from(
item: ZonedDateTimeLike,
options?: ZonedDateTimeFromOptions,
): ZonedDateTime compare(
one: ZonedDateTimeLike,
two: ZonedDateTimeLike,
): number interface Temporal.ZonedDateTimeFromOptions
Properties
offset:
"use"
| "ignore"
| "prefer"
| "reject"
| undefined
optional
interface Temporal.ZonedDateTimeLikeObject
extends DateTimeLikeObject
Properties
offset: string | undefined optional
interface Temporal.ZonedDateTimeToStringOptions
extends PlainDateTimeToStringOptions
Properties
offset:
"auto"
| "never"
| undefined
optional
timeZoneName:
"auto"
| "never"
| "critical"
| undefined
optional
namespace Temporal
Interfaces
Temporal.DateTimeLikeObject
No documentation available
Temporal.Duration
No documentation available
Temporal.DurationLikeObject
No documentation available
Temporal.DurationRoundingOptions
No documentation available
Temporal.DurationToStringOptions
No documentation available
Temporal.Instant
No documentation available
Temporal.InstantConstructor
No documentation available
Temporal.PlainDate
No documentation available
- add
- calendarId
- day
- dayOfWeek
- dayOfYear
- daysInMonth
- daysInWeek
- daysInYear
- equals
- era
- eraYear
- inLeapYear
- month
- monthCode
- monthsInYear
- since
- subtract
- toJSON
- toLocaleString
- toPlainDateTime
- toPlainMonthDay
- toPlainYearMonth
- toString
- toZonedDateTime
- until
- valueOf
- weekOfYear
- with
- withCalendar
- year
- yearOfWeek
Temporal.PlainDateTime
No documentation available
- add
- calendarId
- day
- dayOfWeek
- dayOfYear
- daysInMonth
- daysInWeek
- daysInYear
- equals
- era
- eraYear
- hour
- inLeapYear
- microsecond
- millisecond
- minute
- month
- monthCode
- monthsInYear
- nanosecond
- round
- second
- since
- subtract
- toJSON
- toLocaleString
- toPlainDate
- toPlainTime
- toString
- toZonedDateTime
- until
- valueOf
- weekOfYear
- with
- withCalendar
- withPlainTime
- year
- yearOfWeek
Temporal.PlainDateTimeToStringOptions
No documentation available
Temporal.PlainMonthDay
No documentation available
Temporal.PlainTime
No documentation available
Temporal.PlainTimeToStringOptions
No documentation available
Temporal.PlainYearMonth
No documentation available
Temporal.TimeLikeObject
No documentation available
Temporal.ToStringRoundingOptions
No documentation available
Temporal.ToStringRoundingOptionsWithFractionalSeconds
No documentation available
Temporal.YearMonthLikeObject
No documentation available
Temporal.ZonedDateTime
No documentation available
- add
- calendarId
- day
- dayOfWeek
- dayOfYear
- daysInMonth
- daysInWeek
- daysInYear
- epochMilliseconds
- epochNanoseconds
- equals
- era
- eraYear
- getTimeZoneTransition
- hour
- hoursInDay
- inLeapYear
- microsecond
- millisecond
- minute
- month
- monthCode
- monthsInYear
- nanosecond
- offset
- offsetNanoseconds
- round
- second
- since
- startOfDay
- subtract
- timeZoneId
- toInstant
- toJSON
- toLocaleString
- toPlainDate
- toPlainDateTime
- toPlainTime
- toString
- until
- valueOf
- weekOfYear
- with
- withCalendar
- withPlainTime
- withTimeZone
- year
- yearOfWeek
Namespaces
Temporal.Now
No documentation available
Type Aliases
Temporal.CalendarLike
No documentation available
Temporal.DateUnit
No documentation available
Temporal.DurationLike
No documentation available
Temporal.InstantLike
No documentation available
Temporal.PartialTemporalLike
No documentation available
Temporal.PlainDateLike
No documentation available
Temporal.PlainDateTimeLike
No documentation available
Temporal.PlainMonthDayLike
No documentation available
Temporal.PlainTimeLike
No documentation available
Temporal.PlainYearMonthLike
No documentation available
Temporal.PluralizeUnit
No documentation available
Temporal.TimeUnit
No documentation available
Temporal.TimeZoneLike
No documentation available
Temporal.ZonedDateTimeLike
No documentation available
namespace Temporal.Now
Functions
Temporal.Now.instant
No documentation available
Temporal.Now.plainDateISO
No documentation available
Temporal.Now.plainDateTimeISO
No documentation available
Temporal.Now.plainTimeISO
No documentation available
Temporal.Now.timeZoneId
No documentation available
Temporal.Now.zonedDateTimeISO
No documentation available
type alias Temporal.CalendarLike
Definition
type alias Temporal.DateUnit
Definition
"year"
| "month"
| "week"
| "day"
type alias Temporal.DurationLike
Definition
type alias Temporal.InstantLike
Definition
type alias Temporal.PartialTemporalLike
type alias Temporal.PlainDateLike
Definition
type alias Temporal.PlainDateTimeLike
Definition
type alias Temporal.PlainMonthDayLike
Definition
type alias Temporal.PlainTimeLike
Definition
type alias Temporal.PlainYearMonthLike
Definition
type alias Temporal.PluralizeUnit
type alias Temporal.TimeUnit
Definition
"hour"
| "minute"
| "second"
| "millisecond"
| "microsecond"
| "nanosecond"
type alias Temporal.TimeZoneLike
Definition
ZonedDateTime | string type alias Temporal.ZonedDateTimeLike
Definition
variable caches
The global CacheStorage instance, providing access to the named Cache objects used to store and retrieve Request/Response pairs.
Type
Provides access to the Cache API. Returns a CacheStorage object, which enables storing, retrieving, and managing request/response pairs in a cache.
Examples
// Open (or create) a cache
const cache = await caches.open('v1');
// Store a response
await cache.put('/api/data', new Response('Hello World'));
// Retrieve from cache with fallback
const response = await caches.match('/api/data') || await fetch('/api/data');
// Delete specific cache
await caches.delete('v1');
// List all cache names
const cacheNames = await caches.keys();
// Cache-first strategy
async function fetchWithCache(request) {
const cached = await caches.match(request);
if (cached) return cached;
const response = await fetch(request);
const cache = await caches.open('v1');
await cache.put(request, response.clone());
return response;
}
Type
See
© 2018–2025 the Deno authors
Licensed under the MIT License.
https://docs.deno.com/api/web/uncategorized