defaultRuntime variable

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

The default Runtime includes two functions, datetime and number.

Signature:

defaultRuntime: {
    datetime: typeof datetime;
    number: typeof number;
}

Remarks

  • datetime accepts an optional Date, number or string as its argument and formats it with the same options as Intl.DateTimeFormat. If not given any argument, the current date/time is used. - number accepts a number, BigInt or string representing a number as its argument and formats it with the same options as Intl.NumberFormat. It also supports plural category selection via Intl.PluralRules