3 ms·
That post is misguided for so many reasons. In order to say something 'forms a monad', you need to define over what operations. That poster assumes Promise form
by tathougies 8y ago
That post is misguided for so many reasons. In order to say something 'forms a monad', you need to define over what operations. That poster assumes Promise forms a monad using regular javascript function composition as the function composition operator. This is stated without justification, and there are other notions of javascript function composition which would preserve the functor composition law.
More clearly, Promise indeed forms a functor, if the domain is the set of Javascript functions which do not return 'Promise<X>'.