t
tRPC
How to properly handle errors on the client - tRPC
K
tRPC
•
11mo ago
•
2 replies
Kamil
How to properly handle errors on the client
I throw
TRPCError
TRPCError
error in the procedure under certain conditions
. On the client I query the procedure and check the error with
isError
isError
flag returned by hook
.
The problem is it bubbles the error to the very top crashing entire application
. How to stop it bubbling and make it catchable with
isError
isError
flag
? The documentation is poor about handling errors on the client
.
It
's Next 15 with Turbopack and the
"new
" Tanstack React Query integration
.
tRPC
Join
Move Fast & Break Nothing. End-to-end typesafe APIs made easy.
4,951
Members
View on Discord
Resources
ModelContextProtocol
ModelContextProtocol
MCP Server
Recent Announcements
Similar Threads
Was this page helpful?
Yes
No
Similar Threads
How to handle Query Errors on client side (show toast on 401)
M
Mattèo / ❓-help
3y ago
how to handle non-trpc errors?
P
pupo / ❓-help
9mo ago
Express + tRPC: handle express errors from client
R
Reador / ❓-help
3y ago