You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to setup i18next with TypeScript, but get a bunch of errors, here it is:
node_modules/i18next/typescript/t.d.ts:71:46 - error TS2589: Type instantiation is excessively deep and possibly infinite.
71 [Ns in FlatNamespace]: WithOrWithoutPlural<KeysBuilder<Resources[Ns], false>>;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/i18next/typescript/t.d.ts:121:30 - error TS2536: Type '$FirstNamespace<ActualNS>' cannot be used to index type 'Keys'.
121 | ParseKeysByKeyPrefix<Keys[$FirstNamespace<ActualNS>], KPrefix>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/i18next/typescript/t.d.ts:217:58 - error TS2322: Type '$FirstNamespace<Ns>' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
Type 'Ns | Ns[0]' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
Type 'Ns' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
Type 'Namespace' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
Type 'symbol' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
Type 'string | number | symbol' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
Type 'symbol' is not assignable to type 'string | number | bigint | boolean | null | undefined'.
217 $TFunctionBrand: $IsResourcesDefined extends true ? `${$FirstNamespace<Ns>}` : never;
~~~~~~~~~~~~~~~~~~~
node_modules/i18next/index.d.ts:279:22 - error TS2589: Type instantiation is excessively deep and possibly infinite.
279 TKPrefix extends KeyPrefix<ActualNs> = undefined,
~~~~~~~~~~~~~~~~~~~
My TypeScript version is 5.1.3.
I have a complex tsconfig.*.json structure, but here is the most important one – tsconfig.checks.json:
I am trying to setup i18next with TypeScript, but get a bunch of errors, here it is:
My TypeScript version is
5.1.3
.I have a complex
tsconfig.*.json
structure, but here is the most important one –tsconfig.checks.json
:The text was updated successfully, but these errors were encountered: