routing
new new default Router Export ({
linkActiveClass : ' Active ', the CSS class name to use when activating the link provided // Default options may be configured by the route. linkActiveClass
configured to global
routes: [
]
})
css
.nav .active {
color: #ffbb22;
}
stencil
<div class="nav"> <router-view></router-view> <router-link class="nav-item" to="/nav1">nav1</router-link> <router-link class="nav-item" to="/nav2">nav2</router-link> <router-link class="nav-item" to="/nav3">nav3</router-link> </div>