Intl.DateTimeFormat.formatToParts - Web documentation
method Intl.DateTimeFormat.formatToParts

Allow locale-aware formatting of strings produced by Intl.DateTimeFormat formatters.

Parameters

optional
date: Formattable | number

The date to format.

Return Type

globalThis.Intl.DateTimeFormatPart[]