Something is wrong w tRPC and NextJS dx

1 koolyy 0 6/3/2025, 1:37:10 PM
Been working in a t3 monorepo and often times tiny ui changes result in having to touch 8-10 different files. Our trpc routes have grown exponentially and each dev is almost adding a new route for each specific feature. We have endpoints that return massive amounts of data fetched by hooks and modifying the prisma query often results in type errors in unrelated files.

I have a strong feeling that something is wrong in our trpc & react query hooks' structure or organization and its severely impacted the dev experience. Does anyone have experience scaling a trpc nextjs application? Are there any code structure or patterns that you use to do trpc the "right" way?

I'm coming from a dotnet / laravel stack and minor ui changes would never have spanned more than 2-3 files. It's hard to find examples of companies using trpc in production and since its new there isn't a lot of info about good practices around it.

Comments (0)

No comments yet