摘要: watch: { $route: { handler(val, oldval) { if (val != oldval) { location.reload();//重新加载数据 } }, // 深度观察监听 deep: true } }, 阅读全文
posted @ 2022-11-09 16:30 搬砖的L先生 阅读(66) 评论(0) 推荐(0) 编辑
摘要: 第一种解决方法: 将vue路由模式mode: 'history' 修改为 mode: 'hash'; //router.js文件 const router = new Router({ //mode: 'history', mode: 'hash', routes: [ { path: '/', r 阅读全文
posted @ 2022-11-09 14:39 搬砖的L先生 阅读(2865) 评论(0) 推荐(0) 编辑