vue 路由传递参数

router.js

 {
          path: '/updateVideo',
          name: 'UpdateVideo',
          component: UpdateVideo,
   }

vue中

      this.$router.push({ name: "UpdateVideo", params: { id: id } });//页面跳转

    console.log("========" + this.$route.params.id); 获取参数

猜你喜欢

转载自blog.csdn.net/qq_25430563/article/details/88371524