Fork me on GitHub
#re-frame
<
2020-06-15
>
rberger03:06:24

Is re-frame.core/dispatch-n still a valid thing? Its not working for me and its not in https://github.com/day8/re-frame/blob/master/src/re_frame/core.cljc?

rberger03:06:42

I see it in re-frame.fx

mikethompson03:06:53

So it is an effect

mikethompson03:06:04

Not a function

rberger03:06:18

So only call it from a reg-event-fx?

mikethompson03:06:38

It is valid but you use it within an event handler

mikethompson03:06:36

(def-event-fx 
  :event 
  (fn [cofx e] 
    {:dispatch-n  [[:one] [:two]]
     :db   ....}))  

mikethompson03:06:46

notice it is data (key)

mikethompson03:06:58

Not a function to call

rberger03:06:33

Yes, ok, didn’t realize that.