Fork me on GitHub
#missionary
<
2021-11-26
>
ribelo17:11:19

Is there any sensible way to make flow from m/mbx or does it not make any sense and I should just use (m/watch atom) as user input?

ribelo17:11:02

in general, if I want to make an infinite loop calling a side effect, I guess there is no need to use flow and a sp with loop inside, similar to go-loop will probably be a better idea?

leonoel18:11:50

To make a discrete flow from a repetition of tasks, the general pattern is

(def m (m/mbx))
  (m/ap
    (loop []
      (m/amb> (m/? m)
        (recur))))

leonoel18:11:39

you may consider observe too

ribelo18:11:12

oh, I finally learned by example what amb> is for

ribelo18:11:28

amb> has no example in the documentation or in the wiki, and I think this is a pretty good example

leonoel18:11:28

yes, it's a common pattern it should be in the wiki

ribelo18:11:18

Is there anything like frp patterns for dummies?

ribelo18:11:29

I would love to read 🙃