Przeglądaj źródła

fix(KeepAlive): remove cached VNode properly (#5260)

fix #5258
edison 4 lat temu
rodzic
commit
2e3e183b4f

+ 1 - 1
packages/runtime-core/src/components/KeepAlive.ts

@@ -174,7 +174,7 @@ const KeepAliveImpl: ComponentOptions = {
     function unmount(vnode: VNode) {
       // reset the shapeFlag so it can be properly unmounted
       resetShapeFlag(vnode)
-      _unmount(vnode, instance, parentSuspense)
+      _unmount(vnode, instance, parentSuspense, true)
     }
 
     function pruneCache(filter?: (name: string) => boolean) {