i18next-fetch-backend icon indicating copy to clipboard operation
i18next-fetch-backend copied to clipboard

Cant get Multiloading to work and translation key depth problem

Open Creatium opened this issue 2 years ago • 0 comments

Hey,

Trying to make everything work, but have some problems.

  1. I have allowMultiloading set to true and my loadPath to /locales/resources.json?lng={{lng}}&ns={{ns}}. I also have multiple namespaces ns set (array with names). So plugin does load all namespaces, but does so in multiple requests. Not sure what I am missing. Trying many different options, with no success. What works though is if I set ns to string, instead of array, like so: ns1+ns2.

  2. Not related to first issue, but I have problems using the loaded translations. Not sure if this is related to your plugin or not. Loaded translations look like this: { "en": { "ns1": { "key": "Value" } } }. And so if I try to show this Value like this t('ns1:key') it will simply not work. The only way this works is by typing t('en.ns1.key'). What am I missing here?

Creatium avatar Feb 21 '24 14:02 Creatium