This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-06-09
Channels
- # beginners (121)
- # boot (28)
- # cider (106)
- # clara (57)
- # cljs-dev (70)
- # cljsrn (6)
- # clojure (145)
- # clojure-dev (7)
- # clojure-italy (36)
- # clojure-russia (42)
- # clojure-spec (26)
- # clojure-uk (127)
- # clojurescript (103)
- # core-async (10)
- # cursive (56)
- # datascript (66)
- # datomic (16)
- # defnpodcast (1)
- # emacs (18)
- # events (6)
- # figwheel (1)
- # jobs (1)
- # luminus (1)
- # lumo (44)
- # off-topic (58)
- # om (17)
- # onyx (2)
- # parinfer (75)
- # pedestal (4)
- # re-frame (18)
- # ring (4)
- # ring-swagger (8)
- # rum (7)
- # spacemacs (7)
- # specter (2)
- # sql (4)
- # unrepl (39)
- # untangled (17)
- # vim (3)
- # yada (21)
I'm stuck with getting https://github.com/Semantic-Org/Semantic-UI-React to work with Rum
I'm not sure how to get external components to work with rum and googling just yields this: https://github.com/tonsky/rum/issues/20
I'm hoping to be able to get a https://react.semantic-ui.com/views/card#card-example-groups working with rum
got it working... but is there a better way?
(defcs home-page [state]
[:div {:on-click (start-drag state)}
[:h2 "home"]
(js/React.createElement js/semanticUIReact.Card
#js {}
(js/React.createElement js/semanticUIReact.Card.Content
#js {}
(js/React.createElement js/semanticUIReact.Card.Header
#js {} "Matthew")))])
@zcaudate this is what I have for react native components:
(defn create-element [rn-comp opts & children]
(apply js/React.createElement rn-comp (clj->js opts) children))
(def view (partial create-element (.-View ReactNative)))
;; and later:
(rum/defc foo []
(view {:key a}
(h3 {} "bar")))