I'm sure this has been asked and answered, but maybe I'm not able to phrase it correctly to find the right results.
Say I have two redux middleware operations:
- a call to create an asset entity in the backend, then update the state with the result
- a call to upload the asset data (requires the ID created on the create)
If I want to compose these two middleware operations into a single one how should I go about it? I thought a thunk made sense but I don't seem to have a way to get the resulting ID back from the first dispatch without diffing the before/after state.