-
-
Notifications
You must be signed in to change notification settings - Fork 10.6k
404 route handling does not work on page reload #12995
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
This is resolved by #13500 and will be available in the next release 👍 |
🤖 Hello there, We just published version Thanks! |
🤖 Hello there, We just published version Thanks! |
I'm using React Router as a...
library
Reproduction
Repository
Core reproduction code:
System Info
Used Package Manager
npm
Expected Behavior
When loading a route that doesn't exist in the route definition (logging
No routes matched location...
, I expect that theerrorElement
orErrorBoundary
is renderedActual Behavior
The
errorElement
/ErrorBoundary
is rendered when doing a client-side navigation but not when reloading the page. Note that this only seems to break when the route has aloader
defined — without it, both expectations are met.This means that a user who mistypes a route or uses an outdated bookmark will get a white screen instead of 404 UI.
This worked in 7.1.3 but is broken in 7.1.4 onwards.
The text was updated successfully, but these errors were encountered: