浏览代码

remove the mount information when a node is dismounted

Evan Almloff 1 年之前
父节点
当前提交
41abffb267
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      packages/core/src/diff/node.rs

+ 3 - 0
packages/core/src/diff/node.rs

@@ -213,6 +213,9 @@ impl VNode {
         // Clean up the roots, assuming we need to generate mutations for these
         // This is done last in order to preserve Node ID reclaim order (reclaim in reverse order of claim)
         self.reclaim_roots(mount, dom, to, gen_muts);
+
+        // Remove the mount information
+        dom.mounts.remove(mount.0);
     }
 
     fn reclaim_roots(