This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-10-30
Channels
- # beginners (32)
- # boot (15)
- # cljs-dev (200)
- # cljsjs (1)
- # cljsrn (18)
- # clojure (4)
- # clojure-austin (2)
- # clojure-spec (6)
- # clojure-uk (8)
- # clojurescript (69)
- # cloverage (1)
- # cursive (12)
- # datomic (1)
- # dirac (37)
- # emacs (1)
- # hoplon (38)
- # off-topic (3)
- # om (19)
- # om-next (1)
- # onyx (4)
- # parinfer (2)
- # perun (27)
- # protorepl (4)
- # re-frame (5)
- # rum (9)
- # spacemacs (8)
- # untangled (2)
@wielderofmjolnir @shaun-mahood Why is the doall block there?
@curlyfry It's to force evaluation. I first did map
, but it gives of a warning:
> Reactive deref not supported in lazy seq, it should be wrapped in doall:
So the deref
of active-tab
requires it, I think 🙂
@wielderofmjolnir Huh, never seen that! Probably just haven't derfed in a map/for in my projects.
@curlyfry You're comment made me realize I should probably just use a local variable to hold the dereffed value outside of the doall
, instead of dereffing it for every item, since the @active-tab
stays the same through the loop. Insane performance gain right there!