3 ms·
s/React/Redux? (for example) With setState in React, you don't necessarily have to copy to update the state. setState merges the partial object you provide wit
by nishs 4y ago
s/React/Redux? (for example)
With setState in React, you don't necessarily have to copy to update the state. setState merges the partial object you provide with the current state.
https://reactjs.org/docs/state-and-lifecycle.html#state-updates-are-merged https://reactjs.org/docs/state-and-lifecycle.html#state-upda...
In Redux reducers, however, you need a full copy.