Awaiting block expression

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Awaiting block expression

guest271314


```await [null].reduce(async user => fetch('/image/'+ (await user).image).json(), fetch('/user/'+id).json())``` 

Or use ```Promise.all()```. Or an immediately invoked async arrow function where a value is ```return```ed from the function.

How do you propose to get the values declared within block scope (a different scope)?

_______________________________________________
es-discuss mailing list
[hidden email]
https://mail.mozilla.org/listinfo/es-discuss