diff options
| author | Adam Soltys <[email protected]> | 2024-01-26 00:06:00 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2024-01-26 00:33:50 -0800 |
| commit | 3444b3c0fb349395a02d6db1eeaef57460b1a37f (patch) | |
| tree | af815eafd6c6075d49c8231efd955531376d993e /src/routes/+layout.js | |
| parent | 01fdad8ee4e6bb4213c0c81a8876cda67ad3085a (diff) | |
| download | coinos-ui-3444b3c0fb349395a02d6db1eeaef57460b1a37f.tar.gz coinos-ui-3444b3c0fb349395a02d6db1eeaef57460b1a37f.zip | |
update translations
Diffstat (limited to 'src/routes/+layout.js')
| -rw-r--r-- | src/routes/+layout.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/routes/+layout.js b/src/routes/+layout.js new file mode 100644 index 00000000..03c7ec49 --- /dev/null +++ b/src/routes/+layout.js @@ -0,0 +1,14 @@ +import { addTranslations, setLocale, setRoute } from '$lib/translations'; + +/** @type {import('@sveltejs/kit').Load} */ +export const load = async ({ data }) => { + const { i18n, translations } = data; + const { locale, route } = i18n; + + addTranslations(translations); + + await setRoute(route); + await setLocale(locale); + + return i18n; +}; |
