vue-element-admin icon indicating copy to clipboard operation
vue-element-admin copied to clipboard

隐藏<tag-view>组件,导致菜单的nochache:false 失效

Open godcloudy opened this issue 2 years ago • 1 comments

我把needTagsView的needTagsView值设置为false后(tags-view v-if="needTagsView" ref="tv"),来回点击切换菜单,会不断触发菜单页的mounted事件,也就是路由中的nochache:false设置失效了

Steps to reproduce(问题复现步骤)

Screenshot or Gif(截图或动态图)

Link to minimal reproduction(最小可在线还原demo)

Other relevant information(格外信息)

  • Your OS:
  • Node.js version:
  • vue-element-admin version:

godcloudy avatar Sep 28 '23 09:09 godcloudy

我把tags-view标签的v-if改为v-show就没有这个问题了tags-view v-show="needTagsView" ref="tv"

godcloudy avatar Sep 28 '23 09:09 godcloudy