redux-async-transitions
This module is a combination of following two modules along with features included redux-async and redux-history-transition
thanks to the author
NOTE: All the code blocks are written with ES6
Installation
npm install --save redux-async-transitions
How to Use
;;const store = createStore;
Features
Function calls
Apart from path transition like this
return type: typesSOMEFUNCTION payload: data: somedata meta: path : '/somePath' query: someKey: 'someQuery' state: stateObject: stateData ;
we can have another function to be called while executing a function, were the page transition happens only after executing the function (someOtherfunction)
return type: typesSOMEFUNCTION payload: data: somedata meta: { return ; } path : '/somePath' query: someKey: 'someQuery' state: stateObject: stateData ;
async function calls
return types: typesPENDINGFUNCTION typesSUCCESSFUNCTION typesFAILUREFUNCTION payload: response: someapi // only return promise meta: { } { } { } ;
for each async functions we can have path and also a function like below
{ return { return ; } path : '/somePath' query: someKey: 'someQuery' state: stateObject: stateData }