Hacker News new | ask | show | jobs
by joostdevries 3633 days ago
I was recently thinking while working with ES6 Promises that I liked to have something equivalent to Haskells `do` notation. Or Scalas `for` comprehension.

Does something like that exist?

If not maybe I should try Kleislis instead. But I'd like my code to be accessible for my colleagues. And it's my rule of thumb that I try not to use point free constructions (like Kleislis) because a lot of colleagues will no longer understand my code easily.

1 comments

On second thought: I guess Async Await are like a `do` notation specifically for Promises...
That's true. await sequence actions much like do notation.
..and it's flat instead of nesting.