Gets information about a site's languages.
The siteLanguages
property returns an array of SiteLanguage
objects containing information about all the languages that a site is set
to display in.
import wixWindowFrontend from "wix-window-frontend";
// ...
let languages = wixWindowFrontend.multilingual.siteLanguages;
/* languages is:
* [
* {
* "name": "English",
* "locale": "en-us",
* "languageCode": "en",
* "countryCode": "USA",
* "isPrimaryLanguage": true
* }, {
* "name": "Spanish",
* "locale": "es-es",
* "languageCode": "es",
* "countryCode": "ESP",
* "isPrimaryLanguage": false
* }, {
* "name": "Chinese",
* "locale": "zh-cn",
* "languageCode": "zh",
* "countryCode": "CHN",
* "isPrimaryLanguage": false
* }
* ]
*/