vivo / MoonBox

月光宝盒:无侵入的流量录制与回放平台 A server-side traffic capture and replay platform with noninvasive
Apache License 2.0
1.17k stars 193 forks source link

routes.js添加缓存配置cache: true但是keep-alive未生效 #63

Open qcl1024 opened 9 months ago

qcl1024 commented 9 months ago

record/index.vue中实现页面缓存用的 Utils.getLocalStorage,能够生效;但是在 client\src\router\routes.js 中配置 /mock/index 页面增加缓存配置 cache: true 不生效?打印日志发现 第二次进入页面的时候created钩子被再次调用,没找到keep-alive未生效的原因,可否看一下如何处理? { path: '/mock/index', component: () => import(/ webpackChunkName: 'mock' / 'views/mock/index'), name: 'mock', meta: { title: '回放Mock', cache: true } },