Why would I use api route if trpc api route exists?

Should I always use the trpc api route? Is the normal Next Auth api just supposed to exist for other third parties to use?
the nextauth route is for nextauth. trpc route is for trpc. if you want api routes for external use it’s best to setup api routes for them specifically
So, if I want my own app to use my apis I should them um up in api/trpcroute and if I want them to be consumed externally I set them up in /api ?
UUUnknown User12/2/2022
2 Messages Not Public
Sign In & Join Server To View
You can yes, but its not really designed to be done that way.
UUUnknown User12/3/2022
Message Not Public
Sign In & Join Server To View

Looking for more? Join the community!

Want results from more Discord servers?
Add your server
Recommended Posts
useQuery with useStatehey all!, my question is how to optimize the useQuery search because now whenever the input changes Decimal in PrismaHas anyone dealt with Decimal in Prisma? I am having issues with it when I retrieve results and try How to add routing to a Vite VanillaJS app?Is there a way to have native (i.e. without js) routing in a VanillaJS Vite app? I just want to haveType 'ZodObject{ id ZodNumber; first_name ... missing but required in _procedureSo im trying to pass the logic I had on my Nest + Prisma + GraphQL to the ct3 stack and im a beginneHow to implement cursor-based infinite scrolling with prisma + useInfinitequeryHow to implement cursor based infinite scrolling in this scenario? Imagine I have this schema: ```tuseMutation invalidation fails```const { mutate: updateUserData } = trpc.userInfo.updateUserInfo.useMutation({ async onMutate(trpc.user.getUser.useQueryDoes anyone know how to call onSuccess using the above wrapper of useQuery?Conditional rendering on TS typeHey everyone, I have a timeline that has multiple types coming over the wire in a list, and I need tBest state management for react chrome extensions?Im looking into making a chrome extension. It will be handling a somewhat complex state, shared betwuseQuery error```const { data: user, isError } = trpc.userInfo.getUser.useQuery( [reactQueryKeys.currentUser],how to delete user (next-auth)Doesn't seem like next-auth provides a delete user method at the moment. Right now, I'm just deletinPassing URL Params to TRPC causes Error on First Render, as URL-Param is undefinedI am not sure if I am missing something, but I can't get this to work. I am getting some `id` passedtRPC Input from a Prisma SchemaIs there any way to tell tRPC (zod technically i guess) to expect a tRPC schema as a type? like `prts, mjs, jsWhen do I use which file extensions?