From 4f111948be2e36141786ad10cd0c0fee143ab714 Mon Sep 17 00:00:00 2001 From: Marco Rodolfi Date: Tue, 24 Jan 2023 15:42:41 +0100 Subject: [PATCH] Added correct url path of the loopback server. --- frontend/src/i18n.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/frontend/src/i18n.ts b/frontend/src/i18n.ts index f03dac85..df268557 100644 --- a/frontend/src/i18n.ts +++ b/frontend/src/i18n.ts @@ -6,7 +6,7 @@ i18next .use(Backend) .use(initReactI18next) .init({ - backend:{ + backend: { // path where resources get loaded from, or a function // returning a path: // function(lngs, namespaces) { return customPath; } @@ -17,7 +17,7 @@ i18next // If allowMultiLoading is false, lngs and namespaces will have only one element each, // If allowMultiLoading is true, lngs and namespaces can have multiple elements loadPath: 'https://steamloopback.host:1337/locales/{{lng}}/{{ns}}.json', - + // your backend server supports multiloading // /locales/resources.json?lng=de+en&ns=ns1+ns2 // Adapter is needed to enable MultiLoading https://github.com/i18next/i18next-multiload-backend-adapter @@ -31,7 +31,7 @@ i18next // } allowMultiLoading: false, // set loadPath: '/locales/resources.json?lng={{lng}}&ns={{ns}}' to adapt to multiLoading - reloadInterval: false // can be used to reload resources in a specific interval (useful in server environments) + reloadInterval: false, // can be used to reload resources in a specific interval (useful in server environments) }, debug: true, fallbackLng: 'en', @@ -40,7 +40,7 @@ i18next interpolation: { escapeValue: false, }, - load: 'languageOnly' + load: 'languageOnly', }); export default i18next;