From 5a18b7dd727efabaf3e92bc8867aec974f008334 Mon Sep 17 00:00:00 2001 From: wanchun <445436867@qq.com> Date: Thu, 18 Aug 2022 10:41:44 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8Dplugin-layout=E6=8A=8A?= =?UTF-8?q?=E6=9C=AA=E7=BC=93=E5=AD=98=E9=A1=B5=E9=9D=A2=E5=BD=93=E5=81=9A?= =?UTF-8?q?undefined=E4=B8=A2=E8=BF=9B=E7=BC=93=E5=AD=98=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E5=87=BA=E7=8E=B0=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/fes-plugin-layout/src/runtime/views/page.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/fes-plugin-layout/src/runtime/views/page.vue b/packages/fes-plugin-layout/src/runtime/views/page.vue index 8ebf0b35..7712d1dc 100644 --- a/packages/fes-plugin-layout/src/runtime/views/page.vue +++ b/packages/fes-plugin-layout/src/runtime/views/page.vue @@ -49,7 +49,7 @@ export default defineComponent({ // 此时route已变,但是页面还未加载 const name = changePageComName(route); // 缓存的关键是组件name在keep-alive的include列表 - if (!keepAlivePages.value.includes(name)) { + if (name && !keepAlivePages.value.includes(name)) { keepAlivePages.value = [...keepAlivePages.value, name]; } });