-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Admin UI: cleaned up react-router usage to match latest recommendations #3029
Conversation
🦋 Changeset is good to goLatest commit: 1665f98 We got this. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Blah, why does this "Async callback was not invoked within the 5000ms" test failure keep happening :( |
Yeah, I dunno, but it's a right pain in the butt :-( If you or someone else has some time to get to the bottom of it that'd be great. |
As of
react-router
5.1 it's recommended to usechildren
+ hooks instead ofrender
orcomponent
. 5.1 also included a fix tochildren
so they no longer render when the route doesn't match.These changes should make it easier for me to upgrade to v6 once it comes out.
children
for routes instead ofrender
. I decided to stick with prop form since this is going to be renamedelement
in router v6 with children reserved for nested routes.useParams
for route paramsMinor code formatting:
HomePage
: moved theDocTitle
down into<main>
and dropped the enclosingFragment
ListNotFoundPage
: simplified string construction