Skip to content

Commit

Permalink
【fix】修复路由页面没有加key,渲染出错问题
Browse files Browse the repository at this point in the history
  • Loading branch information
WangZhenHao committed Oct 31, 2023
1 parent 05620be commit e6bdf0e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/views/home/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,13 @@
<component
:is="Component"
v-if="$route.meta.KeepAlive !== false"
:key="$route.name"
/>
</keep-alive>
<component
:is="Component"
v-if="$route.meta.KeepAlive === false"
:key="$route.name"
/>
</router-view>
<!-- <KeepAlive>
Expand Down

0 comments on commit e6bdf0e

Please sign in to comment.