News for hackers. Stuff that matters.
Re:Evolution of the Heroku CLI: 2008-2017 by itwy on Sunday September 03, 2017 @11:42AM (#15161999)
These are not the same. Promise.all guarantees a is executed then b then c.

Your version guarantees the three are executed before moving forward. The order may differ on each run.

Re:Evolution of the Heroku CLI: 2008-2017 by exogen on Sunday September 03, 2017 @02:04PM (#15162843)
FYI, Promise.all does not guarantee that. It doesn't orchestrate actually running the Promises at all (this is impossible the way Promises work), just that they're all resolved at the end, with results in the same order they were passed in.
Re:Evolution of the Heroku CLI: 2008-2017 by itwy on Sunday September 03, 2017 @02:42PM (#15163063)
What is the difference then?
Re:Evolution of the Heroku CLI: 2008-2017 by hdhzy on Sunday September 03, 2017 @03:37PM (#15163394)
None from the perspective of the consumer.

The implementation of Promise.all could use one array for results and fill it in any order as soon as any promise resolves while awaits will always proceed in strict order (like a generator). But that's an implementation detail that a JS programmer doesn't need to think about.

Re:Evolution of the Heroku CLI: 2008-2017 by itwy on Sunday September 03, 2017 @04:14PM (#15163603)
Thanks for the clarification.