title: dynamic array in Promise.all
body: <p>if add promise to array after Promise.all - it will be ignored</p>
  
  <pre><code>let pr = [];
  let start = Date.now();
  
  pr.push(new Promise((resolve) =&gt; {
      setTimeout(() =&gt; {
          resolve();
      }, 2000);
  }));
  
  Promise.all(pr).then(() =&gt; {
      console.log('All done' + (Date.now() - start));
  });
  
  pr.push(new Promise((resolve) =&gt; {
      setTimeout(() =&gt; {
          resolve();
      }, 4000);
  }));
  </code></pre>
  
  <blockquote>
    <p>All done2000</p>
  </blockquote>
  
  <p>How can i do it?</p>