title: Multiple dispatch calls from component react/redux
body: <p>I don't really know why I can't get this to work. All the evidence talks against it...This is the situation:</p>
  
  <p>I have a grid of data and a search panel. When the search panel is changed the searchparams are updated and used for updating the data grid.</p>
  
  <p>The thing which triggers the chain is when the user changes the search panel. In my component i handle search panel changes with this:</p>
  
  <pre><code>  getPhotos(key, value) {
      const change = [{ key: key, value: value},{ key: 'page', value: 1}]
      this.props.dispatch(updateSearchParams(change))
  
      console.log('payload.searchParams', this.props.searchParams);
  
      this.props.dispatch(
        getPhotos(
          { context:this.props.params.context,
            searchParams: this.props.searchParams }
        )
      );
    }
  </code></pre>
  
  <p>Thus two dispatch calls to action creators form the component. The problem is that the searchparams are not updated in time for the getPhotos call, so the grid is not updated accordingly.</p>
  
  <p>I thought that dispatch calls were synchronous - thus one after the other. I guess that it is the round trip from the component, to the action creator, to the store and reducer which is "screwing" it up.
  The first call does not involve any asynchronous calls. </p>
  
  <p>What is the "right" way of doing this? Please be specific about what goes in the component, the action creator and the reducer.</p>
  
  <p>Thanks</p>