You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
store.dispatch(resourceCreateRequest({ title: 'foo' })).then((detail) => {
// detail is the action payload property
console.log('Yaay!', detail)
}).catch((error) => {
// error is the action payload property
console.log('Oops!', error)
})
I'm using the entities/resource pattern outlined in this repo and it seems that detail above is always the id of the resource I am creating/updating. I'm assuming this is so it works with the entities/normalizr pattern? Is there any way to have it return the actual entity object or get access to it somehow from within the resource dispatch promise? I am using resource dispatches a lot in redux-form onSubmits.
Thank you
The text was updated successfully, but these errors were encountered:
From the redux-saga-thunk docs:
I'm using the entities/resource pattern outlined in this repo and it seems that
detail
above is always the id of the resource I am creating/updating. I'm assuming this is so it works with the entities/normalizr pattern? Is there any way to have it return the actual entity object or get access to it somehow from within the resource dispatch promise? I am using resource dispatches a lot in redux-form onSubmits.Thank you
The text was updated successfully, but these errors were encountered: