← Back to release summary

DateTimeFormat dateStyle and timeStyle

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

Summary

Adds dateStyle and timeStyle options to functions on Intl.DateTimeFormat, specifically formatToParts() and resolveOptions(). These options provide a compact way to request the appropriate, locale-specific date and time of given length styles.

Standards & signals

Docs: https://goo.gl/v7n7zV

View on chromestatus.com