watch: {
$route(to, from) {
console.log(to);
if (to.path == '/main/home') {
this.actived = 0
} else if (to.path == '/main/lesson') {
this.actived = 1
} else if (to.path == '/main/my') {
this.actived = 2
}
}
},
watch: {
$route(to, from) {
console.log(to);
if (to.path == '/main/home') {
this.actived = 0
} else if (to.path == '/main/lesson') {
this.actived = 1
} else if (to.path == '/main/my') {
this.actived = 2
}
}
},