router-link-active class is removed if the route is not exact
See original GitHub issueVersion
3.0.3
Reproduction link
https://codesandbox.io/embed/zrjv12l0rp
Steps to reproduce
- Click on Home
- Click on Nested 2
What is expected?
Home should have router-link-active
class
What is actually happening?
router-link-active
is removed from Home on route change
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
Angular Routing routerLinkActive class not getting removed ...
But i want to empty path when i was in home. And i dont want to use [routerLinkActiveOptions]="{ exact: true }" because when...
Read more >RouterLinkActive - Angular
Tracks whether the linked route of an element is currently active, and allows you to specify one or more CSS classes to add...
Read more >RouterLinkActive in Angular - TekTutorialsHub
The RouterLinkActive is a directive for adding or removing classes from an HTML element that is bound to a RouterLink .
Read more >NavLink - React Router: Declarative Routing for React.js
In React Router v6, activeClassName will be removed and you should use the function ... class/style will only be applied if the location...
Read more >API Documentation | Vue Router
Normalized version of a route record. ... for web applications with no host (e.g. file:// ) or when configuring a server to handle...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
It means
router-link-active
works only in some cases since v3.0.3 and it’s expected ?Glad to see that an issue is considered an issue after 3 reports https://github.com/vuejs/vue-router/issues/2724