title: RxJS wait for an observable to complete in its entirety
body: <p>I'm trying to get an Observable to complete in its entirety (meaning the Complete function is called) before the next Observable executes. I've tried many different things, but the closest I've gotten is this:</p>
  
  <pre><code>function() {
    observableA.subscribe(
      (value) =&gt; { },
      (err) =&gt; { },
      () =&gt; {
        createObservableB();
      }
    );
    return observableB; // ????
  }
  </code></pre>
  
  <p>But I need to return the result from createObservableB() from this function. Again, createObservableB cannot be called until every single value in observableA has been iterated over in its entirety.</p>
  
  <p>Thanks for any help!</p>