If they are removed from the dom, then the components get unmounted (and if
you toggle it back then it is mounted again). If you hide them with css but
don't remove them then they do not get unmounted/remounted.

Which you do depends on what you want, I guess, (and how expensive any work
you do in will/did-mount and will-unmount is) but in general I unmount
components I don't currently need.

On Wed, 15 Jul 2015 17:27 Tyler Morten <[email protected]> wrote:

> I guess I was assuming you needed both of the fields to be in the DOM
> (only need one to be displayed on screen at a time).  If not, then you can
> eliminate the display fn and just build the component you need in the DOM.
>
> --
> 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.
>

-- 
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.

Reply via email to