NickN
tRPC3y ago
14 replies
Nick

trpc.legacyRouterName.procedure "does not exist" on type CreateTRPCNextBase, runs anyway

Have reached the end of a massive trpc 9 -> trpc 10 migration, executed using the official guide with conventions copied from the tRPC Prisma starter. (big thanks to @alex / KATT and @Nick Lucas for your support on here while I frustratingly hacked on our massive codebase)

When running legacy procedures such as
trpc.tasks.getAllTasks.useQuery(...)
,
.tasks
will throw the
"does not exist on type CreateTRPCNextBase<Router..."
type error, but will run successfully anyway.

The only procedures I can see are my v10 router's
greeting
procedure and router methods such as
useContext()
.

Any insight or direction toward solving this issue would be greatly appreciated!

I wonder if this is a result of our legacy middleware?
Screen_Shot_2023-06-07_at_11.12.37_AM.png
Screen_Shot_2023-06-07_at_11.24.44_AM.png
Screen_Shot_2023-06-07_at_11.21.34_AM.png
Was this page helpful?