I found an example of using D3 with Om at [1] which I used as a basis for a Reagent-based code at [2]. This is little more than a messy experiment now but it works. (Translation: don't judge my horrible code. ;)
In short, the pattern was to use Reagent or Om to produce a placeholder node during the render phase, then actually render the D3 visualization during component-did-mount and component-did-update. You can plug into those with Reagent using reagent/create-class rather than a simple function, which can be seen at [2]. I haven't bothered getting smooth D3 transitions going with this, but that should be possible as well. [1] https://github.com/seancorfield/om-sente/blob/master/src/cljs/om_sente/core.cljs#L262 [2] https://github.com/rbrush/clara-tools/blob/master/src/main/clojurescript/clara/tools/apps/logicview/graph.cljs#L74 -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/clojurescript.
