diff --git a/src/karax.nim b/src/karax.nim index 737f3ef..a1597a3 100644 --- a/src/karax.nim +++ b/src/karax.nim @@ -38,6 +38,7 @@ type runCount: int components: seq[ComponentPair] surpressRedraws*: bool + byId: JDict[cstring, VNode] when defined(stats): recursion: int @@ -112,12 +113,19 @@ template detach(n: VNode) = template attach(n: VNode) = n.dom = result + if n.id != nil: kxi.byId[n.id] = n proc applyEvents(n: VNode; kxi: KaraxInstance) = let dest = n.dom for i in 0..