4 ms·
ES7 has `async function(){}` and `await call();` syntax proposal that adds the promise/generator trick to the language. http://wiki.ecmascript.org/doku.php?id=
by pornel 13y ago
ES7 has `async function(){}` and `await call();` syntax proposal that adds the promise/generator trick to the language.
http://wiki.ecmascript.org/doku.php?id=strawman:async_functions http://wiki.ecmascript.org/doku.php?id=strawman:async_functi...
- jmtulloss 13y agoThis syntax has been borrowed from other languages and is tried and true. I feel that the author intuited that something like this would be nice, but wasn't aware of async/await and so proposed something that only kind of vaguely points in the right direction. I don't think he's wrong that something like this would be nice, but async/await is a much more robust way of dealing with this!