Questions tagged [vue-i18n]

Use when referencing the vue-i18n plugin for Vue.js

Internationalization plugin for Vue.js.

Github Documentation

567 questions
0
votes
1 answer

Vue-i18n doesn't work properly in the data method?

Multilingual folder i18n contents are as follows: src lang cn.js us.js index.js The contents of the index.js file are as follows: import VueI18n from 'vue-i18n' import Vue from 'vue' Vue.use(VueI18n) const i18n = new…
qingyun1029
  • 45
  • 1
  • 9
0
votes
1 answer

vue-i18n single file component in laravel project

Given a Laravel 5.5 project, I want to use the "single file component" of the vue-i18n plugin. Documentation. It seems simple, but I can't get it to work. app.js import VueI18n from 'vue-i18n' Vue.use(VueI18n) const i18n = new VueI18n({ locale:…
Jeffrey
  • 1,766
  • 2
  • 24
  • 44
0
votes
1 answer

Internalization, languages files and administration

I have a project built on vue which uses v-i18n to manage all the language and caption in a website. All the languages are then stored into .js files Situation There will probably have a lot of changes to do over time. Question I'm wondering what…
Léo Coco
  • 4,022
  • 11
  • 52
  • 97
0
votes
2 answers

Is it possible to parse Vue.js data with jQuery?

I have a line of jQuery code: $("#showNames").text("{{ $t('hide_labels') }}"); I'd like to set text of the #showNames element with the value taken from my vue-i18n instance, dependent on user localization. When it's written this way, I get the…
AbreQueVoy
  • 1,748
  • 8
  • 31
  • 52
0
votes
1 answer

Vue.JS check if vue-i18n is installed

i got a little Problem, i'm creating a vuejs package in which i use vue-i18n to translate things. The Problem is, if the user haven't got vue-i18n installed it breaks the package (obviously since i use it). Do you know a way to prevent this? My…
ExCluSiv3
  • 98
  • 1
  • 7
-1
votes
0 answers

Single-spa subapp renderd but not displaying

I have a main app using Nuxt2 and Vue. And I try to add a microfrontend using single-spa library. The subapp rendered in the main app without any errors but it is not displaying. I also use vue-i18n. Asynchronous functions in plugins section which…
Tea
  • 16
  • 4
-1
votes
3 answers

Vue 3 vue-i18n. How to use $t(t) outside the app(.vue files)? Composition API

I want to format my date-time outside the component. function transformDatetime(config, value) { if (value) { return $d(new Date(value), config); } return $t('-'); } I'm trying to get $t from the App instance. But it only works…
SerGDaN
  • 9
  • 3
-1
votes
1 answer

Adding hyperlink with href to named formatting I18n vuejs

I've looked at the vue documentation on this page to see how I can solve this: https://kazupon.github.io/vue-i18n/guide/formatting.html#named-formatting I think i have all the syntaxes correct and I have tried many different scenarios with the href…
petterandersson
  • 71
  • 2
  • 10
-1
votes
1 answer

How to disable open redirect in Nuxt app?

My app is allowing users to redirect to another websites. If you try https://velas-deploy.herokuapp.com//example.com/ it will be redirected to example.com or any other website you want. Is there any way to disable it? I'm using Nuxt + i18n.
-1
votes
1 answer

Internazionalization in VUE i18n for long text paragraph

What's the best approach in using VUE i18n for a long text paragraph? I know that I can use backticks (``) and even preserve carriage return but is this the way to go? Or is better to conditionally load different JSON files according to the locale…
EanX
  • 475
  • 4
  • 21
-1
votes
1 answer

How to get data from database for vue-i18n?

I want to get language data for i18n from database. I use session storage for save data then get data from API. But i18n created before session storage get data from database. How can I create session storage before create i18n? i18n store call
-2
votes
2 answers

Vue meta i18n variable name showing instead of value

I Have a vue2 project with vue-meta and i have vue-i18n to localize the project. In my browser bookmark the title of the webpage is not shown. The variable is shown instead. Same issue when looking in google analytics it seems that my variable is…
crunchwrap
  • 31
  • 9
1 2 3
37
38