VueJS exact-active-class
You can use v-if
to check which route you're in and add class if $route.name
is somewhere
<ul class="nav nav-second-level">
<li v-for="item in menu" :class="{ 'IS-ACTIVATED': $route.name === somewhere }">
<router-link :to="{ name: somewhere }">
{{Name}}
</router-link>
</li>
</ul>