You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I'm trying to bubble my exception up to the error boundary in the root for specific errors only. I have tried checking the error type in the child boundaries and re-throwing the errors, but this resulted in an infinite loop (of the error being thrown and caught in the same component). Is there any way of achieving this functionality? Thanks!
createBrowserRouter([{errorElement: <ErrorElement1/>,// <-- 3. Specific errors should be caught here insteadchildren: [{errorElement: <ErrorElement2/>,// <-- 2. Errors are caught hereelement: <Element/>// <-- 1. Error is thrown here}]}])
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello, I'm trying to bubble my exception up to the error boundary in the root for specific errors only. I have tried checking the error type in the child boundaries and re-throwing the errors, but this resulted in an infinite loop (of the error being thrown and caught in the same component). Is there any way of achieving this functionality? Thanks!
Beta Was this translation helpful? Give feedback.
All reactions