I want to update a specific property in each object in redux state, and assume I have this kind of main state
networkFailure: true
employer: {
signUp: {
data: null
error: null
loading: true
}
}
user: {
signUp: {
data: null
error: null
loading: false
}
}
Assume I have faced to a network failure, then the networkFailure state becomes true , and with that I need to fail(false) loading signUp state of the employer and all loading status to the false value of other objects too
Is that possible to do this in one reducer? or any suggestions for do it in a better way? I have setup 3 reducer functions for employer, user and network