diff --git a/karax/karax.nim b/karax/karax.nim index 3dcd4a3..ccde9b5 100644 --- a/karax/karax.nim +++ b/karax/karax.nim @@ -170,8 +170,9 @@ proc toDom*(n: VNode; useAttachedNode: bool; kxi: KaraxInstance = nil): Node = result = document.createTextNode(n.text) attach n elif n.kind == VNodeKind.verbatim: - result = document.createElement("div") - result.innerHTML = n.text + var t = document.createElement("template") + t.innerHTML = n.text + result = t.content attach n return result elif n.kind == VNodeKind.vthunk: