cleanup dom's PR
This commit is contained in:
parent
9068686614
commit
9882d1aec2
1 changed files with 3 additions and 1 deletions
|
|
@ -4,6 +4,7 @@ import kdom, vdom, jstrutils, compact, jdict, vstyles
|
||||||
|
|
||||||
export kdom.Event, kdom.Blob
|
export kdom.Event, kdom.Blob
|
||||||
|
|
||||||
|
when defined(nimNoNil):
|
||||||
{.experimental: "notnil".}
|
{.experimental: "notnil".}
|
||||||
|
|
||||||
proc kout*[T](x: T) {.importc: "console.log", varargs, deprecated.}
|
proc kout*[T](x: T) {.importc: "console.log", varargs, deprecated.}
|
||||||
|
|
@ -140,6 +141,7 @@ proc vnodeToDom*(n: VNode; kxi: KaraxInstance): Node =
|
||||||
elif n.kind == VNodeKind.verbatim:
|
elif n.kind == VNodeKind.verbatim:
|
||||||
result = document.createElement("div")
|
result = document.createElement("div")
|
||||||
result.innerHTML = n.text
|
result.innerHTML = n.text
|
||||||
|
attach n
|
||||||
return result
|
return result
|
||||||
elif n.kind == VNodeKind.vthunk:
|
elif n.kind == VNodeKind.vthunk:
|
||||||
let x = callThunk(vcomponents[n.text], n)
|
let x = callThunk(vcomponents[n.text], n)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue