i18next 23.4.9 → 23.5.1

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.
@@ -1 +1 @@
1
- {"type":"module","version":"23.4.9"}
1
+ {"type":"module","version":"23.5.1"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "i18next",
3
- "version": "23.4.9",
3
+ "version": "23.5.1",
4
4
  "description": "i18next internationalization framework",
5
5
  "main": "./dist/cjs/i18next.js",
6
6
  "module": "./dist/esm/i18next.js",
@@ -1,5 +1,5 @@
1
1
  export type $MergeBy<T, K> = Omit<T, keyof K> & K;
2
- export type $Dictionary<T = any> = { [key: string]: T };
2
+ export type $Dictionary<T = unknown> = { [key: string]: T };
3
3
  export type $OmitArrayKeys<Arr> = Arr extends readonly any[] ? Omit<Arr, keyof any[]> : Arr;
4
4
  export type $PreservedValue<Value, Fallback> = [Value] extends [never] ? Fallback : Value;
5
5
  export type $SpecialObject = object | Array<string | object>;
@@ -685,7 +685,7 @@ export interface TOptionsBase {
685
685
  /**
686
686
  * Default value to return if a translation was not found
687
687
  */
688
- defaultValue?: any;
688
+ defaultValue?: unknown;
689
689
  /**
690
690
  * Count value used for plurals
691
691
  */
package/typescript/t.d.ts CHANGED
@@ -134,7 +134,10 @@ type ParseInterpolationValues<Ret> =
134
134
  | (Value extends `${infer ActualValue},${string}` ? ActualValue : Value)
135
135
  | ParseInterpolationValues<Rest>
136
136
  : never;
137
- type InterpolationMap<Ret> = Record<$PreservedValue<ParseInterpolationValues<Ret>, string>, any>;
137
+ type InterpolationMap<Ret> = Record<
138
+ $PreservedValue<ParseInterpolationValues<Ret>, string>,
139
+ unknown
140
+ >;
138
141
 
139
142
  type ParseTReturnPlural<
140
143
  Res,
@@ -208,6 +211,7 @@ type AppendKeyPrefix<Key, KPrefix> = KPrefix extends string
208
211
  **************************/
209
212
  export interface TFunction<Ns extends Namespace = DefaultNamespace, KPrefix = undefined> {
210
213
  $TFunctionBrand: $IsResourcesDefined extends true ? `${$FirstNamespace<Ns>}` : never;
214
+
211
215
  <
212
216
  const Key extends ParseKeys<Ns, TOpt, KPrefix> | TemplateStringsArray,
213
217
  const TOpt extends TOptions,
@@ -134,7 +134,10 @@ type ParseInterpolationValues<Ret> =
134
134
  | (Value extends `${infer ActualValue},${string}` ? ActualValue : Value)
135
135
  | ParseInterpolationValues<Rest>
136
136
  : never;
137
- type InterpolationMap<Ret> = Record<$PreservedValue<ParseInterpolationValues<Ret>, string>, any>;
137
+ type InterpolationMap<Ret> = Record<
138
+ $PreservedValue<ParseInterpolationValues<Ret>, string>,
139
+ unknown
140
+ >;
138
141
 
139
142
  type ParseTReturnPlural<
140
143
  Res,