You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I'm looking to build a multi-lingual app with a JSON each for every supported language (only a handful). So, in addition to requesting the key that I want, I also need to specify the locale that I care about.
Instead of $t("helloWorld"), I need to be able to specify say $t("helloWorld", "en_US") or $t("helloWorld", "fr_FR").
Alternatively, even something like $en("helloWorld") and $fr("helloWorld") could do as well.
Can you describe what can I do to achieve this? The former allows me to have one accessorFunctionName, but it doesn't appear that I can add multiple arguments. The latter means I need to specify more than one accessorFunctionName.
The text was updated successfully, but these errors were encountered:
In my use-case, each locale is separated into its own 1-dimensional object where the locale to lookup is resolved within the accessor function.
There's currently no way to add more parameters with the existing API, but happy to review a PR that would add support for a hook that tells the plugin how to parse custom function calls.
Hi, I'm looking to build a multi-lingual app with a JSON each for every supported language (only a handful). So, in addition to requesting the key that I want, I also need to specify the locale that I care about.
Instead of
$t("helloWorld")
, I need to be able to specify say$t("helloWorld", "en_US")
or$t("helloWorld", "fr_FR")
.Alternatively, even something like
$en("helloWorld")
and$fr("helloWorld")
could do as well.Can you describe what can I do to achieve this? The former allows me to have one
accessorFunctionName
, but it doesn't appear that I can add multiple arguments. The latter means I need to specify more than oneaccessorFunctionName
.The text was updated successfully, but these errors were encountered: