Fork me on GitHub
#reagent
<
2018-03-12
>
kucerm213:03:41

How to pass component as other compoment atributt in hiccup?

kucerm213:03:54

I need somthing like

kucerm213:03:39

[:> ui/popup {:trigger other-ui-component}]

kucerm213:03:32

(def popup (component "Popup"))

kucerm213:03:40

(defn component "Get a component from sematic-ui-react: (component \"Button\") (component \"Menu\" \"Item\")" [k & ks] (if (seq ks) (apply goog.object/getValueByKeys semantic-ui k ks) (goog.object/get semantic-ui k)))

kucerm213:03:54

(def semantic-ui js/semanticUIReact)

mikerod15:03:26

@kucerm2 is other-ui-component a Reagent component? If so, how about r/as-element

kucerm217:03:10

Thanx, as-element is solution!

dimovich20:03:36

@gadfly361 is it possible to cache the svg in rid3?

gadfly36121:03:25

@dimovich unfortunately haven't explored that before