路由跳转并关闭当前tabs标签页

// 关闭当前tabs
this.$store.dispatch("tagsView/delView", this.$route);
// 跳转路由
this.$router.replace({ path: '/test' });

// 返回
this.$router.go(-1);
this.$router.push({path: path, query: param}); // 跳转
this.$route.query.paramName; // 接收

若依关闭页签不会销毁 keep-alive 缓存的组件

使用 keep-alive 缓存的组件。离开该页签时,组件状态为 inactive;点击该页签时,组件状态为 active。

点击按钮关闭该页签 this.$tab.closePage(view),该组件被销毁。

Vue2 若依常见问题_若依常见问题