1
This commit is contained in:
@@ -58,6 +58,11 @@ router.beforeEach((to, from, next) => {
|
||||
}
|
||||
})
|
||||
|
||||
router.afterEach(() => {
|
||||
router.afterEach((to) => {
|
||||
NProgress.done()
|
||||
// 移动端不渲染 TagsView,其 watch 里的 addTags 不会执行,cachedViews 一直为空。
|
||||
// AppMain 中 keep-alive 的 include 依赖 cachedViews,空数组时部分页面(如闲鱼商品)首进可能白屏,需刷新才正常。
|
||||
if (to.name) {
|
||||
store.dispatch('tagsView/addView', to)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user