Search
Star
Feedback
Setup for Free
© 2026 Hedgehog Software, LLC
Twitter
GitHub
Discord
System
Light
Dark
More
Communities
Docs
About
Terms
Privacy
onSuccess, onError and onSettled deprecated next major version? - Theo's Typesafe Cult
TTC
Theo's Typesafe Cult
•
3y ago
•
15 replies
Jinx ᓚᘏᗢ
onSuccess, onError and onSettled deprecated next major version?
with
onSuccess
onSuccess
,
onError
onError
and
onSettled
onSettled
being deprecated soon
, what would the best practice be for triggering side effects
, when a trpc call is successful
?
i should clarify
, i
'm
not
talking about putting the returned data in state
. i
'm talking about refreshing a route in a
"use client"
"use client"
component with
next/router
next/router
, or toggling a boolean in a jotai store
.
Solution
https://tkdodo.eu/blog/breaking-react-querys-api-on-purpose
Breaking React Query's API on purpose
Why good API design matters
, even if it means breaking existing APIs in the face of resistance
.
Jump to solution
Theo's Typesafe Cult
Join
26,268
Members
View on Discord
Resources
ModelContextProtocol
ModelContextProtocol
MCP Server
Recent Announcements
Similar Threads
Was this page helpful?
Yes
No
Similar Threads
handle onError mutation
TTC
Theo's Typesafe Cult / questions
3y ago
trpc global onError
TTC
Theo's Typesafe Cult / questions
3y ago
Next.js Version? How to change?
TTC
Theo's Typesafe Cult / questions
13mo ago
Problems with useQuery.onSuccess()
TTC
Theo's Typesafe Cult / questions
4y ago