This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-07-10
Channels
- # announcements (3)
- # architecture (54)
- # babashka (11)
- # beginners (12)
- # calva (5)
- # clj-on-windows (1)
- # cljdoc (2)
- # cljs-dev (1)
- # cljsrn (6)
- # clojure (130)
- # clojure-europe (8)
- # clojurescript (21)
- # conjure (23)
- # core-async (4)
- # datomic (7)
- # depstar (77)
- # events (1)
- # fulcro (27)
- # lsp (88)
- # malli (5)
- # meander (1)
- # off-topic (4)
- # pathom (43)
- # polylith (39)
- # re-frame (9)
- # shadow-cljs (14)
- # timbre (3)
- # tools-deps (53)
@lilactown Some Background ... I think this idea originally came via @olivergeorge in this thread. https://github.com/day8/re-frame/issues/639#issuecomment-680500053 Because it seemed like a good idea, Isaac made a first round of changes to re-frame to help accommodate better composition: https://day8.github.io/re-frame/releases/2020/#110-2020-08-24 But: • I never wrote proper docs which is a problem because the decision was to add supportive features and then let improved docs look after the rest of the best practice side of this. • I ultimately decided not to go the whole hog and create a new registration function to specifically support composition (reasoning can be seen in that issue thread)
FWIW, what we are doing more or less came from the (somewhat hidden) docs for :fx and the parallels I saw with elm's Cmds. This is the first time I'm seeing this discussion thread
somewhat tangential, but also a neat thing would be if {:fx nil} were valid. Would eliminate the fx/none
we have around paralleling elm's Cmd.none
@U3JH98J4R
Without checking, I suspect {:fx nil}
would work
Certainly {:fx []}
would work
If there is anything we can do to improve experience please create an issue
it does not. nil is not sequential
(if-not (sequential? seq-of-effects)
(console :error "re-frame: \":fx\" effect expects a seq, but was given " (type seq-of-effects))
I’ll gladly contribute to the conversation but it might take me a day or two… I need to compose my thoughts (pun intended)