title: If I yield to a Promise does it wait for the Promise to be resolved before continuing
body: <p>I am struggling to understand how to use generator functions and iterators to achieve various design options for a library I am thinking about writing.</p>
  
  <p>Having got past the simple generator functions, I am now struggling with the examples out there on the internet showing how to integrate generators with Promises.</p>
  
  <p>One problem is all the articles are written before the ES2015 spec on Promises was available and they all use 3 party libraries which I don't know what the nuances are.</p>
  
  <p>So the question I don't really understand is if you yield and the generator function calls .next(Promise returning function) does the statements beyond the yield continue as soon as the .next function is called, or when the returned promise resolves.  The examples seem to imply that it waits until the Promise resolves, but I don't see the logic of why.</p>