Skip to content
dateStyle and timeStyle options for DateTimeFormat
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
.travis.yml Set up continuous integration Oct 14, 2018 Stage 3 Mar 31, 2019
biblio.json Editorial: Fix cross-references. Oct 16, 2018 Deploy whenever on master Oct 14, 2018
github_deploy_key.enc Fix file name Oct 14, 2018
package.json Fix version Oct 14, 2018
spec.html Normative: Use resolved, not input, hourCycle Apr 30, 2019

dateStyle and timeStyle option on Intl.DateTimeFormat API Specification [draft]

This proposal adds two options to Intl.DateTimeFormat: dateStyle and timeStyle. These options give a compact way to request the appropriate, locale-specific way to ask for a date and time of given lengths.


Current Stage:

  • 🚀 Stage 3

Spec Text:


  • Zibi Braniecki (@zbraniecki)


  • ?


This proposal is based on the CLDR Date/Time Patterns:


let o = new Intl.DateTimeFormat("en" , {
  timeStyle: "short"
console.log(o.format(; // "13:31"

let o = new Intl.DateTimeFormat("en" , {
  dateStyle: "short"
console.log(o.format(; // "21.03.2012"

let o = new Intl.DateTimeFormat("en" , {
  timeStyle: "medium",
  dateStyle: "short"
console.log(o.format(; // "21.03.2012, 13:31"

Render Spec

npm install
npm run build
open index.html


You can’t perform that action at this time.