add: frontend profile data etc

This commit is contained in:
$(pass /github/name)
2024-09-10 18:52:32 +02:00
parent f0b2409963
commit b34a85e9d6
21 changed files with 1927 additions and 693 deletions

View File

@@ -0,0 +1,20 @@
import { register, init, getLocaleFromNavigator, locale } from "svelte-i18n";
function setupI18n() {
register("en", () => import("../locales/en.js"));
register("de", () => import("../locales/de.js"));
init({
fallbackLocale: "de",
initialLocale: getLocaleFromNavigator(),
});
}
setupI18n();
/**
* @param {string} newLocale - The new locale to set
*/
export const changeLocale = (newLocale) => {
locale.set(newLocale);
};