lexich/redux-api

Multiple dispatch via async all not working?

Closed this issue · 1 comments

I'm trying to dispatch multiple actions as so:

   search(term) {
      const x = dispatch(rest.actions.type1({ q: 'z' }));
      x.then(() => {
        dispatch(rest.actions.type2({ x: 'y' }));
      });
    },

or variations thereof. I want to dispatch two separate endpoints when search is executed, but I can't get this to work consistently. I've tried various orders, etc., using force(), using sync() -- no matter what I do, either only one of the results returns, etc. What's going on? Any ideas?

Hi @adamdonahue Pls show your configuration.