How do I throw an error on a behaviour subject and continue the stream? : <p>On one end, I have a stream which may occasionally throw an error:</p>

<pre><code>this.behaviorSubject.error(error)
</code></pre>

<p>Later on, however, I want to continue the stream:</p>

<pre><code>this.behaviorSubject.next(anotherValue)
</code></pre>

<p>on the other end, I have a subscriber subscribed to <code>behaviorSubject.asObservable()</code>.</p>

<p>In the subscribtion, I'm handling the value and the error:</p>

<pre><code>.subscribe( 
   ( value ) =&gt;  {  /* ok */ },
   ( error ) =&gt;  {  /* some error */ }
);
</code></pre>

<p>I want the effect to be the same as a simple <code>onSuccess</code> and <code>onError</code> callback, where <code>onError</code> is called every time an error occurs and doesn't prevent future <code>onSuccess</code> calls from being made. How do I do this with RXJS?</p>

<p>I've looked into catch but it seems to just prevent error from being called on subscribers.</p>
