title: wait for state in resolver (ngrx)
body: <p>right now I have a resolver calling standard service and returning an Observable:</p>
  
  <pre><code>return this.someService.getData()
        .map(data=&gt; data.json())
  </code></pre>
  
  <p>I want to replace it with ngrx effects and store. When resolver is run I want to dispatch requestAction intercepted by effect, which makes http request. Once data is returned I dispatch dataReceivedAction with data as payload. </p>
  
  <p>Basically i want to dispatch an action in resolver and wait till new data is in part of store. I try to do it this way:</p>
  
  <pre><code>return Observable.combineLatest(
        Observable.of(
          this.store.dispatch(new requestAction())
        ),
        this.store.select(store =&gt; store.dataIWaitFor),
        (dispatchedAction, dataArrived) =&gt; dataArrived
      )
        .skip(1)
  </code></pre>
  
  <p>it's not working, I mean the resolver doesn't render the component but when at the end of each of these returned Observables I add</p>
  
  <pre><code>.do(data =&gt; console.log(data))
  </code></pre>
  
  <p>the same data is logged.
  What I do wrong?</p>