would like Promise.flatMap to exist
-
-
does this generalise for any monad m? i.e. [m [a]] -> m [a] or even n (m (n a)) -> m (n a), if m and n are monads like, you're flattening one monad that's got another one sandwiched in between
-
Yeah, `sequenceA . (fmap join)` should (not 100% sure I have syntax correct there, but use sequenceA to get `m (n (n a))`, and then fmap join gives you `m (n a)`
- 1 more reply
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.