增加缓存路由

main
JayChou 6 months ago
parent d0ea2d0976
commit 518c32e890
  1. 7
      src/Layout/main/index.vue

@ -4,7 +4,12 @@
<router-view :key="$route.path" />
</transition>
</section> -->
<router-view></router-view>
<router-view v-slot="{ Component }">
<keep-alive>
<component :is="Component"></component>
</keep-alive>
</router-view>
</template>
<script lang="ts" setup>

Loading…
Cancel
Save