Auto locale
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
import i18n from 'sveltekit-i18n';
|
||||
|
||||
export const defaultLocale = 'en';
|
||||
|
||||
const config = ({
|
||||
loaders: [
|
||||
{
|
||||
@@ -19,4 +21,14 @@ const config = ({
|
||||
],
|
||||
});
|
||||
|
||||
export const { t, locale, locales, loading, loadTranslations } = new i18n(config);
|
||||
export const {
|
||||
t,
|
||||
locale,
|
||||
locales,
|
||||
loading,
|
||||
loadTranslations,
|
||||
setLocale,
|
||||
translations,
|
||||
addTranslations,
|
||||
setRoute
|
||||
} = new i18n(config);
|
||||
|
||||
Reference in New Issue
Block a user