Open illjah42 opened 4 years ago
In our work we use lazy-loading translations, provided by https://nuxt-community.github.io/nuxt-i18n/.
Loaded file expects to be like this:
{ key: 'value' }
But the generator outputs something like this, even for --multi-locales flag:
{ en: { key: 'value' } }
The loaded file injects as is, so the translation function can't find $t('key'), because now it is $t(i18n.locale + '.key')
$t('key')
$t(i18n.locale + '.key')
Can we somehow tune the generator to recieve an object, not wrapped in locale key in output?
The same issue! Looking forward!
In our work we use lazy-loading translations, provided by https://nuxt-community.github.io/nuxt-i18n/.
Loaded file expects to be like this:
But the generator outputs something like this, even for --multi-locales flag:
The loaded file injects as is, so the translation function can't find
$t('key')
, because now it is$t(i18n.locale + '.key')
Can we somehow tune the generator to recieve an object, not wrapped in locale key in output?