Async javascript is much more fun when you memoize.
Daniel Brain
89712

Great article!

I got confused by was in your second-to-last complete example,

you dispatch `soupRecipePromise` and save the promise it return in `getSoupRecipe`.

The action of `getSoupRecipe` is new in progress. I thought the code just get soup recipe once.

Such as:

'use strict';

let i = 0;
let autoIncrease = async function() {
  return Promise.resolve(i++);
};
let autoIncreasePromise = autoIncrease();
let main = async function() {
  console.log(await autoIncreasePromise);
  console.log(await autoIncreasePromise);
  console.log(await autoIncrease());
};
main().then(() => console.log('work done!')).catch(console.error);

The result was : 0,0, 1