I want to have just one loader (backdrop and spinner) inside app component and show it when i need (depends on redux state's property called showLoader) in every where of my react application. So I have a global reducer called appReducer
which is contains showLoader property. the question is how can i change showLoader inside another reducer, orderReducer
when i need?
for example when dispatch FETCH_ORDERS_REQUEST
action, showLoader should be true and after that when FETCH_ORDERS_SUCCESS
action dispatched, showLoader should be false.
How can i do that?
Thank you