//错误代码
computed:{
isActive(){
return this.$route.path.indexOf(this.path) !== 1
}
}
//正确代码,忘了减号
computed:{
isActive(){
return this.$route.path.indexOf(this.path) !== -1
}
}
//错误代码
computed:{
isActive(){
return this.$route.path.indexOf(this.path) !== 1
}
}
//正确代码,忘了减号
computed:{
isActive(){
return this.$route.path.indexOf(this.path) !== -1
}
}