This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-06-16
Channels
- # arachne (1)
- # beginners (27)
- # boot (17)
- # cider (10)
- # cljs-dev (5)
- # cljsrn (76)
- # clojure (59)
- # clojure-austin (2)
- # clojure-brasil (1)
- # clojure-greece (76)
- # clojure-mexico (1)
- # clojure-quebec (63)
- # clojure-russia (16)
- # clojure-spec (127)
- # clojure-uk (12)
- # clojurescript (72)
- # community-development (7)
- # core-async (3)
- # core-matrix (2)
- # cursive (13)
- # datomic (8)
- # emacs (4)
- # funcool (4)
- # hoplon (148)
- # immutant (5)
- # keechma (2)
- # lambdaisland (5)
- # lein-figwheel (15)
- # leiningen (20)
- # off-topic (23)
- # om (13)
- # om-next (19)
- # onyx (11)
- # planck (11)
- # re-frame (59)
- # reagent (14)
- # rum (34)
- # specter (30)
- # spirituality-ethics (16)
- # uncomplicate (5)
- # untangled (387)
- # yada (2)
Anyone knows how to use with-ref
with callback as described in https://facebook.github.io/react/docs/more-about-refs.html ?
@honzabrecka: just passing a callback to the with-ref second argument instead of a string?
https://github.com/tonsky/rum/blob/gh-pages/src/rum/core.cljs#L162 rum does nothing special
@niwinz: I know, but I need something like this: (with-ref [:audio [:source {:src “…"}]] #(…))
sablono/compile-html
should be the answer
Great, thank you!
Works great 🙂
@honzabrecka: you don't need with-ref
here: You can just do [:audio {:ref #()} [:source....]]
. Same btw, for :key
.
The with-{ref,key}
is just when you get passed in the component as an argument and construct many of them, then you can change their key on-the-fly.
They'd be called "higher order (react) components". Since they take a comp and return a comp. 🙂
Hi! Can anyone help me with this? https://github.com/tonsky/rum/issues/75 🙂
Hmm, really? 😄 I guess my brain kind of switches off when someone mentions lenses. Thank you, I'll have to look at this in more detail 🙂
lentes comes with a lot of predefined helpers that will make use it much simplier without need to define own lenses
so thinks like focusing on concrete key is as easy as (l/focus-atom (l/key :foobar) state)