title: (JavaScript) Synchronizing forEach Loop with callbacks inside
body: <p>I am doing some computations inside a double <code>forEach</code> Loop something like this:</p>
  
  <pre><code>array.forEach(function(element){
      Object.keys(element).forEach(function(key){
  
          /* some complex computations with asynchronous callbacks  */        
  
      });
  });
  
  someFunctionHere();
  </code></pre>
  
  <p>Is there a way for the Loop to finish first before doing the <code>someFunctionHere( )</code> function? or any way that the program will know if the Loop is finish before continuing to <code>someFunctionHere( )</code> ...</p>
  
  <p>I may be missing some forums but the ones I found did not helped me of what I want to achieve and by the way I am doing this in NodeJS , also I am asking if there are existing libraries that can make this happen.</p>
  
  <p><strong>I forgot to Add this up or should this be an another question?</strong></p>
  
  <p>Is there a way to do the iteration synchronously that it will only proceed to the next iteration once the current iteration is done? (Sorry for this)</p>
  
  <p>Thanks for any help...</p>