← Back to release summary

Intl.DateTimeFormat.prototype.formatToParts()

Category
JavaScript
Type
New or changed feature
Status
Enabled by default (Chrome 57)
Intent stage
None

Summary

Intl.DateTimeFormat.prototype.formatToParts() is scheduled to be added to the EcmaScript Internationalization API specification (Ecma 402). It adds a method to format date and time to a list of tokens and their type (e.g. literal, day, year, month, hour, minute, era, etc).

Standards & signals

Docs: https://github.com/tc39/ecma402/issues/30 https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat/formatToParts https://github.com/zbraniecki/proposal-intl-formatToParts

View on chromestatus.com