Replies: 3 comments
-
Nearly forgot: I also tried it this way: src/i18n/index.tsimport { createI18n } from 'vue-i18n';
import messages from '@intlify/unplugin-vue-i18n/messages';
// import de from './messages/de.json';
// console.log(de);
// eslint-disable-next-line @typescript-eslint/naming-convention
export const SUPPORT_LOCALES = ['de'];
export const i18n = createI18n({
locale: 'de',
fallbackLocale: 'de',
legacy: false,
messages,
}); |
Beta Was this translation helpful? Give feedback.
0 replies
-
Somebody an idea? :/ |
Beta Was this translation helpful? Give feedback.
0 replies
-
Should this ever happen to somebody: check if you by mistake put a number as number instead of as string for testing. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
we're currently starting a new project and we're experiencing something seriously strange with vue-i18n.
We're using the current versions of vue, vue-i18n, vite and also the "unplugin" vue-i18n plugin for vite. For testing we added one locale message, overwrite it in the local scope of the vue component and try to display it. But no matter what we try, We get the message the "key" couldn't be found.
The most weird thing is and I tried it in Firefox as well as in Chrome, I can see the messages in Vue dev tools.
Does somebody have any idea what could be the problem?
Screenshot Firefox console
Screenshot Vue Devtools - I18n Resources - global scope
Screenshot Vue Devtools - I18n Resources - local scope
package.json
yarn.lock
vite.config.ts
src/main.ts
src/i18n/index.ts
src/i18n/messages/de.json
Vue component
Beta Was this translation helpful? Give feedback.
All reactions