From d0416e71cb4355e4fd9ea8f5a2afa071fc47bffb Mon Sep 17 00:00:00 2001 From: Robin Date: Wed, 27 Sep 2023 17:53:04 -0400 Subject: [PATCH] Fix the i18n string scanner Apparently the upgrade to i18next-parser v8 came with the deprecation of this 'useKeysAsDefaultValues' option, and this is the new way to configure that behavior. --- i18next-parser.config.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/i18next-parser.config.js b/i18next-parser.config.js index a12797ee..e5c99251 100644 --- a/i18next-parser.config.js +++ b/i18next-parser.config.js @@ -18,5 +18,6 @@ export default { output: "public/locales/$LOCALE/$NAMESPACE.json", input: ["src/**/*.{ts,tsx}"], sort: true, - useKeysAsDefaultValue: true, + // The key becomes the English version of the string + defaultValue: (_l, _ns, key) => key, };