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
{{ message }}
This repository has been archived by the owner on Feb 14, 2023. It is now read-only.
React's native
useReducer
returns[ state, dispatch ]
.When using a property reducer, we can return a destructurable dispatch function, such that both of the following are valid:
const dispatch = useDispatch(propertyReducer, 'propertyName');
and
const [ propertyValue, dispatch ] = useDispatch(propertyReducer, 'propertyName');
We want to be sure the Component does not subscribe to state changes in the first case, but does in the second case.
The text was updated successfully, but these errors were encountered: