Properties that can be passed into the constructor for utilities/format/date!DateFormatter.

interface DateFormatterProperties {
    defaultFormat?: string;
    defaultParseFormat?: string | string[];
    locale?: string;
    parseTimeZone?: string;
    timeZone?: string;
}

Hierarchy (view full)

Properties

defaultFormat?: string

The default format for formatting dates. See utilities/format/date!DateFormatter.format.

defaultParseFormat?: string | string[]

Either a single format, or one of several possible formats that the input is expected to be in. If specified, the input must exactly match. The syntax is the same as for utilities/format/date!DateFormatter.format.

locale?: string

The locale to use when formatting & parsing the number. If not specified, the current locale is used (see locale module).

parseTimeZone?: string

The time zone of the date being parsed.

timeZone?: string

The time zone of the date being formatted.