tRPCttRPC
Powered by
CaptainC
tRPC•4y ago•
14 replies
Captain

NextJS + TRPC + NX

i have a nextjs application inside a NX monorepo. i have everything for @trpc/server inside a node library. i have moved the utils file inside the SRC folder in the next js project. this way, i have node lib which does all for routing an backend logic. i have another lib for ui. this lib exports dumb ui components.

suppose i wanted to move the trpc utils file to one of my libraries so as to be able to fetch data inside the "dumb components", could i do this and is this correct? right now, im forced to prop drill because applications cant share code in NX. only libs can.

anyone have a pattern for either creating smart components inside NX libs or a pattern for providing context?
tRPCJoin
Move Fast & Break Nothing. End-to-end typesafe APIs made easy.
5,015Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Express tRPC NextJS
MugetsuMMugetsu / ❓-help
3y ago
nextjs middleware trpc authentication
chicoCchico / ❓-help
16mo ago
TRPC with Turborepo Nextjs
LukaLLuka / ❓-help
2y ago