[Bug] Active Nested Route
subhanshu-shukla opened this issue · 1 comments
subhanshu-shukla commented
Version
latest
Reproduction link
Operating System
windows
Device
laptop
Browser & Version
mozilla
Steps to reproduce
Create nested route like senders/sender
What is expected?
Senders link in side bar should be active
What is actually happening?
Senders link in side bar is not active
Solution
Additional comments
isActive() {
if (this.$route && this.$route.path) {
let matchingRoute = this.children.find(c =>
this.$route.path.startsWith(c.link.path)
);
if (matchingRoute !== undefined) {
console.log(matchingRoute);
return true;
}
}
return false;
}
subhanshu-shukla commented