im trying to understand how tRPC handle 400 errors request what i got so far is im doing this in my procedure
if (exam) throw new TRPCError({ code: "BAD_REQUEST" });
if (exam) throw new TRPCError({ code: "BAD_REQUEST" });
and in client im getting an error like so but i want to handle the error in client as i want without getting the nextjs error ui i just want a response with message and 400 status the equivalent of
if (exam) res.status(400).json({message:"you have an error"})
if (exam) res.status(400).json({message:"you have an error"})