← Back to release summary

Intl.DisplayNames

Category
JavaScript
Type
New or changed feature
Status
Enabled by default (Chrome 81)
Intent stage
Prepare to ship

Summary

Provides a new API to get localized names of language, region, script, currency codes of international standard as well as commonly used names of date fields and symbols.

Motivation

To enable developers to get translation of language, region or script display names on the client. Translation of languages, regions or script display names requires large amount of data to transmit on the network, which is already available in most browsers. These display name translations also carry steep data size penalty for developers. This API will allow web developers to shrink the size of their HTML and/ or ECMAScript code without the need to include the human readable form of display names and therefore reduce the download size to decrease latency. Also, this API will reduce the localization cost for the web developers. Our goal is to expose this data through Intl API for use in e.g. language, region and script pickers, etc. Benefit - Reduce download size of apps and therefore improve latency. - Easy for users to build internationalized language, region or script selection UI components (drop down menu or other kinds). - Reduce translation cost for developers. - Consistent translation of language, region and script display name on the web.

Standards & signals

Docs: https://goo.gl/im9wy4

Explainers: https://github.com/tc39/proposal-intl-displaynames

View on chromestatus.com