A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://developer.mozilla.org/en-US/docs/Web/API/WorkerGlobalScope/languagechange_event below:

WorkerGlobalScope: languagechange event - Web APIs

WorkerGlobalScope: languagechange event

Limited availability

Note: This feature is only available in Web Workers.

The languagechange event is fired at the global scope object when the user's preferred language changes.

This event is not cancelable and does not bubble.

Syntax

Use the event name in methods like addEventListener(), or set an event handler property.

addEventListener("languagechange", (event) => { })

onlanguagechange = (event) => { }
Event type

A generic Event.

Examples

You can use the languagechange event in an addEventListener method:

worker.addEventListener("languagechange", () => {
  console.log("languagechange event detected!");
});

Or use the onlanguagechange event handler property:

worker.onlanguagechange = (event) => {
  console.log("languagechange event detected!");
};
Specifications Browser compatibility See also

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4