Я получил ответ от Locize.Большое спасибо!
const isNode = require("detect-node");
const i18nextLocizeBackend = require("i18next-locize-backend");
const { localeSubpaths } = require("next/config").default().publicRuntimeConfig;
const NextI18Next = require("next-i18next/dist/commonjs");
const use = [];
if (isNode) {
const i18nextNodeLocizeBackend = eval(
"require('i18next-node-locize-backend')"
);
use.push(i18nextNodeLocizeBackend);
} else {
use.push(i18nextLocizeBackend.default);
}
module.exports = new NextI18Next({
otherLanguages: ["de"],
localeSubpaths,
use,
saveMissing: true,
backend: {
loadPath: "https://api.locize.io/{{projectId}}/{{version}}/{{lng}}/{{ns}}",
addPath: "https://api.locize.io/missing/{{projectId}}/{{version}}/{{lng}}/{{ns}}",
referenceLng: "en",
projectId: "9dc2239d-a752-4973-a6e7-f622b2b76508",
apiKey: "9f019666-2e71-4c58-9648-e6a4ed1e15ae",
version: "latest"
}
});