Comment on Roy — small functional language that compiles to JavaScriptparentComments−ufo14yActually, there are already monadic interfaces for Javascript async code with widespread use. Promises!http://dojotoolkit.org/reference-guide/dojo/Deferred.html http://api.jquery.com/category/deferred-object/new deferred objects can be created manually or obtained from say, an AJAX function (this is the equivalent of "return")async operations can be chained with the deferred.then method (this is a hybrid of "fmap" and ">>=", aka "bind")
Comments
Actually, there are already monadic interfaces for Javascript async code with widespread use. Promises!
http://dojotoolkit.org/reference-guide/dojo/Deferred.html http://api.jquery.com/category/deferred-object/
new deferred objects can be created manually or obtained from say, an AJAX function (this is the equivalent of "return")
async operations can be chained with the deferred.then method (this is a hybrid of "fmap" and ">>=", aka "bind")