5

I have just started a new project with Vue3 and added vue-i18n version 9 (https://vue-i18n.intlify.dev/guide/) I have set up, but I can't change the language. It's doing the trasnlation since it's changing the {{ $t('message.value') }} to the proper sentence. I'm unable to change the language, only works for the locale language.

I'm receiving this error message in the browser console

You are running the esm-bundler build of vue-i18n. It is recommended to configure your bundler to explicitly replace feature flag globals with boolean literals to get proper tree-shaking in the final bundle.

This is my config, but I can't change it to Spanish

const i18n = VueI18n.createI18n({
  locale: 'en', // set locale
  fallbackLocale: 'en', // set fallback locale
  messages, // set locale messages

})

I would appreciate if you could help me, showing me what I am doing wrong. Many thanks

Bernardao
  • 466
  • 6
  • 23
  • It's working properly and changing the language, but would be nice to know what to do with the warning. – Bernardao Mar 05 '21 at 15:16

1 Answers1

4

You shouldn't see it when running your app in production mode.

When running in development it had been corrected in version v2.0.1

Daniel
  • 108
  • 2
  • 11