add AppMain.vue
This commit is contained in:
parent
0714502aa4
commit
623e071288
18
src/layout/components/AppMain.vue
Normal file
18
src/layout/components/AppMain.vue
Normal file
@ -0,0 +1,18 @@
|
||||
<template>
|
||||
<el-main class="app-main">
|
||||
<router-view v-slot="{ Component, route }" :key="route.path">
|
||||
<transition appear name="fade-transform" mode="out-in">
|
||||
<keep-alive :include="cachedViews">
|
||||
<component :is="Component" :key="route.path" />
|
||||
</keep-alive>
|
||||
</transition>
|
||||
</router-view>
|
||||
</el-main>
|
||||
</template>
|
||||
<script setup>
|
||||
const route = useRoute()
|
||||
const store = useStore()
|
||||
const cachedViews = computed(() => {
|
||||
return store.state.tagsView.cachedViews
|
||||
})
|
||||
</script>
|
||||
Loading…
x
Reference in New Issue
Block a user