fix keep-alive not working

This commit is contained in:
effortcheep 2021-11-05 10:05:42 +08:00 committed by GitHub
parent c2109f0e78
commit cad3950657
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,10 +1,10 @@
<template>
<div class="app-container">
<div class="layout-content">
<keep-alive v-if="$route.meta.keepAlive">
<router-view></router-view>
<keep-alive>
<router-view v-if="$route.meta.keepAlive"></router-view>
</keep-alive>
<router-view v-else></router-view>
<router-view v-if="$route.meta.keepAlive"></router-view>
</div>
<div class="layout-footer">
<TabBar :data="tabbars" @change="handleChange" />