Correctly determine whether routes are active #903

Open
opened 2023-08-14 14:48:36 +02:00 by leuckeju · 0 comments
Member

Sometimes subroutes of routes are active (e.g. we have a route with timetable/ and one timetable/5/ and in both cases the item in the sidenav should be active. Maybe this code snippet helps (it works for the list-group, but not for the list-item-group, as this functions different, but maybe the latter one isn't needed?):

 :value="$route.matched.some(route => route.name === menuItem.name)"
Sometimes subroutes of routes are active (e.g. we have a route with `timetable/` and one `timetable/5/` and in both cases the item in the sidenav should be active. Maybe this code snippet helps (it works for the list-group, but not for the list-item-group, as this functions different, but maybe the latter one isn't needed?): ``` :value="$route.matched.some(route => route.name === menuItem.name)" ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aleksis/AlekSIS-Core#903
No description provided.