From 53bf0fd45adbab661dde58823796bb6c7fec9e82 Mon Sep 17 00:00:00 2001 From: Benny Lichtner Date: Mon, 31 May 2021 19:48:16 -0700 Subject: [PATCH] Fix morph from text node to comment node --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 07508e4..23ced20 100644 --- a/index.js +++ b/index.js @@ -59,7 +59,7 @@ function walk (newNode, oldNode) { return null } else if (newNode.isSameNode && newNode.isSameNode(oldNode)) { return oldNode - } else if (newNode.tagName !== oldNode.tagName || getComponentId(newNode) !== getComponentId(oldNode)) { + } else if (newNode.nodeName !== oldNode.nodeName || getComponentId(newNode) !== getComponentId(oldNode)) { return newNode } else { morph(newNode, oldNode)