You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I learned that this code does not work with Vue 3 + composition API when using another variable then messages
const myMessages = { .... }
const i18n = VueI18n.createI18n({
locale: 'ja', // set locale
fallbackLocale: 'en', // set fallback locale
myMessages, // set locale messages
// If you need to specify other options, you can set other options
// ...
})
I had to explicitly assign it, like so:
const myMessages = { .... }
const i18n = VueI18n.createI18n({
locale: 'ja', // set locale
fallbackLocale: 'en', // set fallback locale
messages: myMessages, // set locale messages
// If you need to specify other options, you can set other options
// ...
})
This should be mentioned in the guide in my opinion
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
About this page: https://vue-i18n.intlify.dev/guide/#javascript
I learned that this code does not work with Vue 3 + composition API when using another variable then
messages
I had to explicitly assign it, like so:
This should be mentioned in the guide in my opinion
Beta Was this translation helpful? Give feedback.
All reactions