mirror of
https://github.com/ajnart/homarr.git
synced 2026-02-27 17:00:54 +01:00
* feat: update prettier configuration for print width * chore: apply code formatting to entire repository * fix: remove build files * fix: format issue --------- Co-authored-by: Meier Lukas <meierschlumpf@gmail.com>
14 lines
437 B
TypeScript
14 lines
437 B
TypeScript
import { supportedLanguages } from ".";
|
|
|
|
const enTranslations = () => import("./lang/en");
|
|
|
|
export const languageMapping = () => {
|
|
const mapping: Record<string, unknown> = {};
|
|
|
|
for (const language of supportedLanguages) {
|
|
mapping[language] = () => import(`./lang/${language}`) as ReturnType<typeof enTranslations>;
|
|
}
|
|
|
|
return mapping as Record<(typeof supportedLanguages)[number], () => ReturnType<typeof enTranslations>>;
|
|
};
|