Comments (5)
Do you have any .json
lang files or only the .php
lang files?
Thanks for the report btw.
from laravel-vue-i18n.
Thanks for the reply @xiCO2k! 🙏
Only traditional .php
lang files, no .json
lang files at all in this application 👍
from laravel-vue-i18n.
got it, will take a look on that case!
from laravel-vue-i18n.
Hey @stevebauman sorry for the delay on this.
I did a try on this repo: https://github.com/xiCO2k/laravel-vue-i18n-app and I did not got the error message.
Can you check if the error is still there, and if possible replicate on this repo?
Thanks
from laravel-vue-i18n.
Probably related to this, but i am getting a similar error when setting up using Laravel and Inertiajs
Translations still work but i get the error.
The app.js configuration
createInertiaApp({
title: (title) => `${title} - ${appName}`,
resolve: (name) => resolvePageComponent(`./Pages/${name}.vue`,
import.meta.glob('./Pages/**/*.vue')),
setup ({el, App, props, plugin}) {
return createApp({render: () => h(App, props)}).
use(plugin).
use(ZiggyVue).
use(vfm).
use(i18nVue, {
resolve: async lang => {
const langs = import.meta.glob('../../lang/*.json');
return langs[`../../lang/${lang}.json`]();
}
}).
use(VueGoogleMaps, {
load: {
key: googleMapsApiKey,
},
}).
mount(el);
},
progress: {
color: '#4B5563',
},
});
If I include a php_
prefix as @stevebauman mentions everything works and error goes away.
from laravel-vue-i18n.
Related Issues (20)
- Vue integration: Unable to translate inside the script tag HOT 4
- Wont work with inerta/vue SSR HOT 3
- Could you please add the example with lang/en/auth.php structure?
- lang and fallbackLang not working HOT 1
- Should not generate extra file while Laravel using json locale file HOT 3
- Translation return key and not value after refreshing page HOT 4
- How can I pass a default value for the case of a non-existent or empty-string translation? HOT 2
- [REQ] React version HOT 1
- Library should work for nested keys in translation files. HOT 1
- Problem with php langs generation HOT 6
- Console error after vue 3.4 update HOT 2
- Language switches from english to the selected language HOT 2
- Update supported vue version to 3.4 HOT 1
- path.key not working at all HOT 1
- [REQ]: React support HOT 1
- Explain difference between trans, wTrans and $t? HOT 1
- Errors when building with TypeScript - `No overload matches this call` HOT 2
- TypeError: Cannot read properties of undefined (reading 'kind') when adding i18n() to plugins in vite.config.js HOT 3
- Object Translation HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laravel-vue-i18n.