vue 监听路由变化

 watch:{
   "$route":function(to,from){
     console.log(to.path)
   }
 }
posted @ 2022-04-04 17:40  柯宝宝智商感人  阅读(33)  评论(0编辑  收藏  举报