Questions tagged [linguijs]
24
questions
0
votes
1
answer
17
views
Translate content from axios response
I use linguijs to handle translation in my Vite Application. I have a locale file in JSON for translated content. I use Axios to handle requests.
The linguijs extract the keys(English) for translation....
0
votes
0
answers
12
views
Is it possible to use linguijs in VUE application?
Hello is there a way how to use this library in VUE.js application?
Thank you
I have tried it in VUE application. Followed manual part how to use it in javascript application.
Included @lingui/core ...
3
votes
2
answers
45
views
Lingui map translated content not showing
I am using Lingui for translation from English to Arabic. I am using an array of objects to display my content. The issue I have is that the Arabic translation for the mapped array is not showing. ...
0
votes
0
answers
33
views
App remounts for non-english locales (@lingui/react, @lingui/core)
I’m working on a chat widget app, that has a series topics/questions in the form of radio buttons that when clicked show a different path of selections to choose from, eventually landing on things ...
0
votes
1
answer
26
views
Ant design typography's ellipsis tooltips usage with Lingui
This:
import { Typography } from 'antd'
import { Trans } from '@lingui/macro'
const TransWithEllipsis = () => {
return (
<Typography.Text ellipsis={{ tooltip: true }}>
<Trans ...
1
vote
2
answers
132
views
Translate static string messages in ReactJs using lingui.js
I am using lingui.js and following https://lingui.js.org/tutorials/react.html. I am able to setup the project and it runs fine also generates the PO file and translation content for content/element ...
0
votes
1
answer
32
views
LinguiJS: remove obsolete entries while keeping manually added ones
I'm trying to remove obsolete entries from my lingui catalogs by using lingui extract --clean. However, the catalogs contain entries that I added by hand, which get removed by this as well. For code ...
0
votes
1
answer
65
views
Pass React Node as i18n Lingui value
I have translated line of text with link. In past it was enough, when text and link was separed and has its own translation, but now copy was changed and in one language I need to place the link in ...
0
votes
0
answers
131
views
Using lingui macro in sveltekit, how to configure babel in svelte.config?
I'm hoping I'm on the right track. I've installed @lingui/core and @lingui/macro,
in my svelte app i have a LanguageProvider
import { i18n } from '@lingui/core'
import {
detect,
fromUrl,
...
1
vote
2
answers
2k
views
Next JS Babel can't resolve 'module'
I've started to develop a multi-language web application with Next JS and Lingui.js
Lingui.js is using babel so I had to install it aswell.
I've followed this tutorial https://blog.logrocket.com/...
3
votes
0
answers
773
views
Lingui and yup validator in NextJS
I have a setup with react-hook-form, yup in NextJS for form validation. Lingui for internationalization (followed this documentation). How to setup internationalization in yup validator which is ...
0
votes
1
answer
245
views
Lingui: Error: Objects are not valid as a React child (found: object with keys {id})
According to the documentation we can use t macro instead of i18n._() call. An example of corresponding macro transformation:
import { t } from "@lingui/macro"
const message = t`Hello World`
...
0
votes
1
answer
207
views
ReactJS - How to create a fallback language function with localeStorage
I am having some trouble deciding on what to do with my language app. As you can see below I use "window.localStorage.setItem(LOCAL_STORAGE_KEY, locale);" to get the browser's locale. I have ...
1
vote
1
answer
760
views
React antd LinguiJS not working on Modal method
I tried to translate the title in antd modal.confirm() but I always receive an error useLingui hook was used without I18nProvider. In other pages the translation is working fine.
Here is my code:
...
0
votes
1
answer
3k
views
Creating a language switcher for i18n app
I am learning how to implement Lingui(i18n) on apps. Everything is setup, but I wanted to know how I should create a language swticher to change between language catalogs on my app.
This is my index....
0
votes
1
answer
841
views
Language Switcher with Lingui (i18n), I want the language chosen to stay throughout the app even when refreshed
I am trying out Lingui for the i18n of an app. I created a language switcher based on the documentation and tutorial, but I wanted to know how should I set it up so that each time I choose a language ...
0
votes
1
answer
461
views
Parsing JSON file to csv
I am trying to parse JSON file to csv.
I've found a json2csv library and it works beside the fact that it expects the json file to be arranged in this way:
[
{
column: value,
column2: value2
},
{
...
0
votes
0
answers
137
views
lingui + webpack Cannot find module './*/messages.js' in production
I have a create-react-app PWA with dynamic loading lingui as in here
it works correctly locally in develop as well as in production mode
But, when deployed in production server, something brakes:
*all ...
3
votes
0
answers
795
views
lingui macros throw error with bable-plugin-macros
I'm using lingui package in my React project with CRA and
I get an error when using lingui/macro modules t method.
When I build project got webpack warning message.
Like this.
Critical dependency: ...
2
votes
1
answer
64
views
What catalog format from webtranslateit.com to select for LinguiJS that will work with plurals?
I am trying to switch from i18next to LinguiJS due to big bundle size of i18next.
I use webtranslateit, which supports these formats.
I currently use i18next json v3 format on webtranslateit:
What ...
1
vote
2
answers
1k
views
I faced with Invalid hook call on react
Here are my scripts that make a navigator for lingui-js.
I faced this error on my local:
×
Error: Invalid hook call. Hooks can only be called inside of the body of a function component. This could ...
0
votes
0
answers
92
views
Linguijs and FilePond format conflict. Can't use { char properly
In the FilePond we should localize text with the use of attributes.
For example labelMaxFileSize="Maximum file size is {filesize}".
In the project we are using js-lingui.
So actual translation would ...
1
vote
1
answer
789
views
The Babel-core module not working with Lingui
I am new to the concept of Localizing my react-application. After doing some research online, It seems as if jsLingui is the best library to use and implement translation on my React application. ...
2
votes
0
answers
236
views
Programmatically compile languages with js-lingui
I recently tried to integrate js-lingui into my react project. The tricky part I can't get right is compiling my languages to js files.
My goal is as follows: I will assemble my languages trough some ...