(dom-node this)
Returns the root DOM node of a mounted component.
Returns the root DOM node of a mounted component.
(force-update-all)
Force re-rendering of all mounted Reagent components. This is probably only useful in a development environment, when you want to update components in response to some dynamic changes to code.
Note that force-update-all may not update root components. This
happens if a component 'foo' is mounted with (render [foo])
(since
functions are passed by value, and not by reference, in
ClojureScript). To get around this you'll have to introduce a layer
of indirection, for example by using (render [#'foo])
instead.
Force re-rendering of all mounted Reagent components. This is probably only useful in a development environment, when you want to update components in response to some dynamic changes to code. Note that force-update-all may not update root components. This happens if a component 'foo' is mounted with `(render [foo])` (since functions are passed by value, and not by reference, in ClojureScript). To get around this you'll have to introduce a layer of indirection, for example by using `(render [#'foo])` instead.
(render comp container)
(render comp container callback-or-compiler)
Render a Reagent component into the DOM. The first argument may be either a vector (using Reagent's Hiccup syntax), or a React element. The second argument should be a DOM node.
Optionally takes a callback that is called when the component is in place.
Returns the mounted component instance.
Render a Reagent component into the DOM. The first argument may be either a vector (using Reagent's Hiccup syntax), or a React element. The second argument should be a DOM node. Optionally takes a callback that is called when the component is in place. Returns the mounted component instance.
(unmount-component-at-node container)
Remove a component from the given DOM node.
Remove a component from the given DOM node.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close