Replies: 1 comment
-
react-query will only propagate errors to the nearest error boundary if you set the
because data fetching errors happen asynchronously, but React can only propagate errors to the nearest error boundary if they occur during rendering, react-query will need to catch and rethrow your error in the next render cycle. So you need to explicitly opt into this behaviour. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I am trying to use
ErrorBoudary
within mynextjs
application but it doesnt seem to work properly. All of my query functions are throwing anError
if something is wrong.When the
me
function throws an error thatErrorBoundary
is not catching it, instead its showing an error popup. This is theErrorBoundary
as found in the exampleIf I use the below component as a child of
ErrorBoundary
then it worksam I missing something?
Beta Was this translation helpful? Give feedback.
All reactions