Skip to content

Commit 44d893e

Browse files
committed
I18nComposable: fix dynamic import of translations
1 parent 7fac817 commit 44d893e

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/i18n/I18nComposable.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,7 @@ async function loadComponentLanguageFile(componentName: string) {
6262
if (!(componentLang in loadedMessages) && i18nLang.value !== 'en') {
6363
// Lazy-load translations. For English we don't load a language file but use the translation keys directly.
6464
// Note that the request is cached and not repeated for parallel calls.
65-
const messages = await import(
66-
// tslint:disable-next-line: trailing-comma
67-
/* webpackChunkName: "lang-[request]" */ `./${i18nLang}/${componentName}.json`
68-
);
65+
const messages = await import(`./${i18nLang.value}/${componentName}.json`);
6966

7067
loadedMessages[componentLang] = messages.default || {};
7168
}

0 commit comments

Comments
 (0)