preferredLanguages

Readable Navigator Languages. It provides web developers with information about the user's preferred languages. For example, this may be useful to adjust the language of the user interface based on the user's preferred languages in order to provide better experience.

Demo

Preferred Languages:
en

Usage

<script lang="ts">
import { preferredLanguages } from "svelte-legos";

const languages = preferredLanguages();

// $languages => readonly string[]
</script>