Writing neat asynchronous Node JS code with Promises
Naren Yellavula

The promise.all example is in my opinion misleading!

The order of the promises is important.

In your example the three promises are only called once each. Not three times — meaning not for every promise.all — only for the first. Therefore the message variable is updeate only once by each promise. So message is never changed by promise.all 2 & 3. This is why in your result the message is always the same.

Like what you read? Give Christian Adler a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.