From b6a1c4606516b6ca2102711ffce9da104fbdb41d Mon Sep 17 00:00:00 2001 From: Rune Botten Date: Mon, 12 Aug 2024 16:36:17 -0700 Subject: [PATCH] fix(core): Update react-i18next to 14.0.2 which fixes a performance regression in that library --- packages/sanity/package.json | 2 +- packages/sanity/src/core/i18n/i18nConfig.ts | 1 - pnpm-lock.yaml | 10 +++++----- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/packages/sanity/package.json b/packages/sanity/package.json index 9e8520a5719..27358fa53b3 100644 --- a/packages/sanity/package.json +++ b/packages/sanity/package.json @@ -240,7 +240,7 @@ "react-copy-to-clipboard": "^5.0.4", "react-fast-compare": "^3.2.0", "react-focus-lock": "^2.8.1", - "react-i18next": "^13.0.1", + "react-i18next": "14.0.2", "react-is": "^18.2.0", "react-refractor": "^2.1.6", "react-rx": "^4.0.0", diff --git a/packages/sanity/src/core/i18n/i18nConfig.ts b/packages/sanity/src/core/i18n/i18nConfig.ts index 30f1249f61d..f80b88b166e 100644 --- a/packages/sanity/src/core/i18n/i18nConfig.ts +++ b/packages/sanity/src/core/i18n/i18nConfig.ts @@ -86,7 +86,6 @@ function createI18nApi({ }, /** @internal */ - // @ts-expect-error types are missing i18next: i18nInstance, } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 123e150c9f8..09aea1eec17 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1624,8 +1624,8 @@ importers: specifier: ^2.8.1 version: 2.12.1(@types/react@18.3.3)(react@18.3.1) react-i18next: - specifier: ^13.0.1 - version: 13.5.0(i18next@23.11.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + specifier: 14.0.2 + version: 14.0.2(i18next@23.11.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) react-is: specifier: ^18.2.0 version: 18.3.1 @@ -9601,8 +9601,8 @@ packages: peerDependencies: react: ^16.8.0 || ^17 || ^18 || ^19 - react-i18next@13.5.0: - resolution: {integrity: sha512-CFJ5NDGJ2MUyBohEHxljOq/39NQ972rh1ajnadG9BjTk+UXbHLq4z5DKEbEQBDoIhUmmbuS/fIMJKo6VOax1HA==} + react-i18next@14.0.2: + resolution: {integrity: sha512-YOB/H1IgXveEWeTsCHez18QjDXImzVZOcF9/JroSbjYoN1LOfCoARFJUQQ8VNow0TnGOtHq9SwTmismm78CTTA==} peerDependencies: i18next: '>= 23.2.3' react: '>= 16.8.0' @@ -20937,7 +20937,7 @@ snapshots: dependencies: react: 18.3.1 - react-i18next@13.5.0(i18next@23.11.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + react-i18next@14.0.2(i18next@23.11.5)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: '@babel/runtime': 7.25.0 html-parse-stringify: 3.0.1