r/coffeescript • u/Lakelava • Jul 29 '19
Are we going to have for await in CoffeeScript?
This syntax is very useful to work with streams.
4
Upvotes
r/coffeescript • u/Lakelava • Jul 29 '19
This syntax is very useful to work with streams.
1
u/Shanebdavis Sep 05 '19
Playing around I came up with this function to bridge the gap. It's not as nice as a built-in language solution, but it's not bad.
I based it on the description of for-await here: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of