InversifyJS icon indicating copy to clipboard operation
InversifyJS copied to clipboard

[inversify] index signature parameter type must be either 'string' or 'number'

Open xenoterracide opened this issue 3 years ago • 4 comments

node_modules/inversify/lib/interfaces/interfaces.d.ts:275:10 - error TS1023: An index signature parameter type must be either 'string' or 'number'.

275         [propertyNameOrArgumentIndex: string | symbol]: Metadata[];
❯ uname -a && node --version && npm explain inversify typescript
Darwin 5c52309d33e3 20.6.0 Darwin Kernel Version 20.6.0: Tue Feb 22 21:10:41 PST 2022; root:xnu-7195.141.26~1/RELEASE_X86_64 x86_64 i386 MacBookPro16,1 Darwin
v16.14.2
[email protected]
node_modules/inversify
  inversify@"^6.0.1" from [email protected]
  node_modules/inversify-express-utils
    inversify-express-utils@"^6.4.3" from [email protected]
    back-end
      [email protected]
      node_modules/back-end
        workspace back-end from the root project
  inversify@"^6.0.1" from [email protected]
  back-end
    [email protected]
    node_modules/back-end
      workspace back-end from the root project

[email protected] dev
node_modules/typescript

xenoterracide avatar May 17 '22 20:05 xenoterracide

yeah and that's right. please upgrade typescript to at least 4.4

PodaruDragos avatar May 17 '22 20:05 PodaruDragos

same issue on typescript v4.7.4 and tsc --version is 4.2.3

timo-kang avatar Jul 19 '22 02:07 timo-kang

oh, I upgraded tsc with 4.7.4 by npm i [email protected] -g, and it worked! thanks

timo-kang avatar Jul 19 '22 02:07 timo-kang

Same issue here. Upgrading to [email protected] worked like a charm !

danielherrerasanchez92 avatar Jul 22 '22 16:07 danielherrerasanchez92