react-i18next 11.11.1 → 11.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ### 11.11.2
2
+
3
+ - feat(typings): support readonly namespaces in TFuncKey [1340](https://github.com/i18next/react-i18next/pull/1340)
4
+
1
5
  ### 11.11.1
2
6
 
3
7
  - feat(types): allow readonly namespaces in useTranslation [1339](https://github.com/i18next/react-i18next/pull/1339)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-i18next",
3
- "version": "11.11.1",
3
+ "version": "11.11.2",
4
4
  "description": "Internationalization for react done right. Using the i18next i18n ecosystem.",
5
5
  "main": "dist/commonjs/index.js",
6
6
  "types": "./index.d.ts",
package/ts4.1/index.d.ts CHANGED
@@ -125,10 +125,9 @@ type NormalizeMultiReturn<T, V> = V extends `${infer N}:${infer R}`
125
125
  : never
126
126
  : never;
127
127
 
128
- export type TFuncKey<
129
- N extends Namespace = DefaultNamespace,
130
- T = DefaultResources
131
- > = N extends (keyof T)[]
128
+ export type TFuncKey<N extends Namespace = DefaultNamespace, T = DefaultResources> = N extends
129
+ | (keyof T)[]
130
+ | Readonly<(keyof T)[]>
132
131
  ? NormalizeMulti<T, N[number]>
133
132
  : N extends keyof T
134
133
  ? Normalize<T[N]>