Hacker News new | ask | show | jobs
by BenoitEssiambre 2240 days ago
I also find promises problematic. I do like async/await though, except for the fact that it relies on promises.

I've been toying with the idea of a promise free async/await implementation lately. I'm interested in feedback anyone would have.

https://github.com/bessiambre/casync

1 comments

Very interesting. I just don't have time to try it out right now.

Perhaps if you create and publish a simple comparison solving a given problem with Promises vs. CaSync it would show that CaSync takes much less code?

That could convince more people to take the time to try it out.

I'm not sure it's much less code. Especially that async/await is integrated into the language now. It's less state, less corner cases, more encapsulation and better performance.

I'm thinking of trying (if I have time) to build a babel transpiler plug-in so you could use it with keywords like async/await instead of explicitly wrapping generator functions. I think the syntax would end up very simple.