vue 如何实现在函数中触发路由跳转 this.$router.push({path:'/index'}) 欢迎加入前端交流群交流知识&&获取视频资料:749539640 1 methods:{ 2 click(){ 3 if(data==1) 4 this.$router.push({path:"/home"}) 5 6 } 7 8 9 }