:do-<anything> is deprecated in Hoplon6
If the value of an attribute is a cell, it will automatically becomes reactive.
Regarding routing, you can just do something like this:
(defn page-for [& routes]
(div :toggle (cell= ((set routes) route)) :style "display: none"))
((page-for "#/module/path1" "#/module/path2"
Sometimes you want to have multiple paths match a content thats why there is a
(set routes) in there.
:style "display: none" bit makes sure that content for different paths won't be visible until the cell handling mechanism kicks in. This might be not necessary soon with Hoplon6.
Similarly passing in the kids to a
page-for DOM element as a vector might not be needed anymore; but haven't tested it yet.
You might ask "Why are there 2 parens around
((page-for ...) ...)?".
That utilizes the fact that DOM elements are functions themselves and when called they will incorporate any further attribute or kid specifications into themselves. The parameters are parsed the same way as in case of the default DOM element constructor functions.
There is also the https://github.com/gf3/secretary library which might help with matching routes but I haven't figured it out yet how.