On 5 feb 2014, at 23:28, David Simmons <shortlypor...@gmail.com> wrote:
> Do you have a simple example of passing child components and then rendering > them as I cannot get this to work - I fairly new to Clojure so it could be > user error. Yeah, that is apparently a bit tricky: see https://github.com/holmsand/reagent/issues/13 And (as mentioned in the issue) the error message you get right now is frankly quite horrible... The "children" parameter passed to components is a vector, so you have to combine it with another vector to make the whole thing work. For example like this: (defn has-children [props children] (into [:div {:style {:color "red"}}] children)) used like this: [has-children "foo" [:i "bar"]] /dan -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.