#deps function parameter is of type {} why ?

8 messages · Page 1 of 1 (latest)

indigo thorn
#

TS2339: Property limit does not exist on type {}
TS2339: Property page does not exist on type {}

the docs shows that this is how it is done but I'm getting type errors, is this intended? or a bug ?

keen escarp
indigo thorn
#

wow thank you so much mate

cloud tangle
#

Yeah, I fell for it too, such a tricky thing...

indigo thorn
# cloud tangle Yeah, I fell for it too, such a tricky thing...

https://devblogs.microsoft.com/typescript/announcing-typescript-6-0-rc/#less-context-sensitivity-on-this-less-functions

Do you think that this is related to the issue we had in the properties' order ?

Today we are excited to announce the Release Candidate (RC) of TypeScript 6.0! To get started using the RC, you can get it through npm with the following command: npm install -D typescript@rc TypeScript 6.0 is a unique release in that we intend for it to be the last release based on the current JavaScript […]

cloud tangle
#

@indigo thorn I am not sure. Becuase in TanStack case it does not depend on method/arrow function syntax, error happens in both cases with incorrect ordering(definition for parameters itself use arrow syntax). This issue might be with what Theo was talking in his last TS video, and that issue was not fixed...

I just tested it with typescript@6.0.0-dev.20260307 and error is still there when using incorrect order.

So no, I think it is not related

indigo thorn
#

This issue might be with what Theo was talking in his last TS video, and that issue was not fixed

Ahaa, yes I remember now, aah that sucks