-
-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Closed
Labels
Description
What version of React Router are you using?
Steps to Reproduce
- Define sibling routes /user and /user-preferences
<BrowserRouter> <Routes> <Route path="/" element={<Root />}> <Route index element={<p>Index</p>} /> <Route path="user" element={<p>User</p>} /> <Route path="user-preferences" element={<p>User Preferences</p>} /> </Route> </Routes> </BrowserRouter>
- Show NavLinks to the routes
const Root = () => ( <> <NavLink to="user">Go to /user</NavLink> <NavLink to="user-preferences">Go to /user-preferences</NavLink> </> )
- Navigate to
/user-preferencespath
Expected Behavior
The link to /user-preferences should have the active class and the link to /user should not have the active class. This is the behavior in [email protected]
Actual Behavior
jkepps, rmtsrc, SuperKXT and t-fritschGlebHihohoLauraAbCoronel and antoineharel
