The inferred type of 'trpc' cannot be named without a reference to '...'
I have a monorepo setup like this:
root
-tsconfig.json
-frontend
--tsconfig.json
-backend
--tsconfig.json
I added a reference in the client tsconfig:
I added
In my root tsconfig, I have:
However, now in my client, when I create my trpc instance:
I get a bunch of typing errors:
Where is this coming from and how can I fix it?
root
-tsconfig.json
-frontend
--tsconfig.json
-backend
--tsconfig.json
I added a reference in the client tsconfig:
I added
"composite": true to my backend tsconfig.In my root tsconfig, I have:
However, now in my client, when I create my trpc instance:
export const trpc = createTRPCReact<AppRouter>();I get a bunch of typing errors:
Where is this coming from and how can I fix it?