Type inference issues after upgrading to Typescript 5+
After upgrading an API consuming project from typescript 4 to 5, my calls to
.query
are inferred to any
instead of the actual type. I've tried a bunch of different things but can't seem to get it to work. I also couldn't find anything specifically related to this wrt. TS5.
I'm assuming the issue is that some compiler settings changed, and this is somehow breaking the import.
What's strange is that the AppRouter
imported from the referenced project seems to have the correct shape, but somehow calling a query
on the router instance still fails.

2 Replies
The issue also persists under TRPC 11
This is the tsconfig of the consuming project: