]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
fix(v-show): fix v-show unmount with falsy value (#1403)
authorunderfin <2218301630@qq.com>
Thu, 25 Jun 2020 14:58:31 +0000 (22:58 +0800)
committerGitHub <noreply@github.com>
Thu, 25 Jun 2020 14:58:31 +0000 (10:58 -0400)
fix #1401

packages/runtime-dom/src/directives/vShow.ts

index 2b1d9caef041e9ca18e2ecf5ef4f389e355bfd2b..d9bf3af54874e521af72fefb96bd49cb500f13da 100644 (file)
@@ -35,8 +35,8 @@ export const vShow: ObjectDirective<VShowElement> = {
       setDisplay(el, value)
     }
   },
-  beforeUnmount(el) {
-    setDisplay(el, true)
+  beforeUnmount(el, { value }) {
+    setDisplay(el, value)
   }
 }