The navigator.languages property exposes the Accept Language header and the languageevent, which is fired on the Window object to notifiy scripts of changes to this value. Both features allow web applications to handle i18n in the client and react to user language changes. This change makes these features available to workers. Specifically, navigator.languages is available on workers and languageevent is fired on workers as well as the main thread.

Documentation

Specification

Editor's draft

Status in Chromium

Blink>Workers


Enabled by default (tracking bug) in:

  • Chrome for desktop release 72

Consensus & Standardization

After a feature ships in Chrome, the values listed here are not guaranteed to be up to date.

  • Shipped/Shipping
  • No signal
  • Shipped/Shipping
  • No signals

Owner

Comments

Navigator.languages on the main thread: https://www.chromestatus.com/feature/6056371904577536

Search tags

workers, languages, navigator,

Last updated on 2020-11-09