but when I call for example "about": {{ $t('general.main_menu.about') }} all I have is a string "general.main_menu.about" not the expected "About".
I will provide here the vite.config.js and app.js.
I'm stuck witht this problem for a day so far. Maybe I'm missing something small and I just can't see it.
Thanks in advance!
vite.config.js:
import {defineConfig} from 'vite';
import laravel from 'laravel-vite-plugin';
import vue from '@vitejs/plugin-vue';
import i18n from 'laravel-vue-i18n/vite';
export default defineConfig({
plugins: [
laravel({
input: ['resources/css/app.css', 'resources/js/app.js'],
refresh: true,
}),
vue({
template: {
base: null,
includeAbsolute: false
}
}),
i18n,
],
});
Hello guys,
I am experiencing an issue with accessing nested translation keys in the plugin. This is my en.json file with some example translations:
en.json:
When I am calling the translation string I want with "{{ $t('general') }}" I'm getting this object which is ok:
but when I call for example "about": {{ $t('general.main_menu.about') }} all I have is a string "general.main_menu.about" not the expected "About".![image](https://github.com/xiCO2k/laravel-vue-i18n/assets/44297075/1e03d8d1-dde5-418b-8cad-7e360c3c8ce1)
I will provide here the vite.config.js and app.js. I'm stuck witht this problem for a day so far. Maybe I'm missing something small and I just can't see it. Thanks in advance!
vite.config.js:
app.js:
I'm using the following versions:
laravel-vue-i18n: "2.4.3" laravel: "10.10"