-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Closed
Description
What version of React, ReactDOM/React Native, Redux, and React Redux are you using?
- React: ^17.0.2
- ReactDOM/React Native:
- Redux:^4.1.2
- React Redux:^7.2.6
What is the current behavior?
useSelector is no longer firing when actions are dispatched via useDispatch
const currentPageIndex = useSelector((state) => state.pageReducer[Constants.ReduxActions.CURRENT_PAGE] ?? defaultPage);
//CurrentPageIndex always returns 0 which is the default page even though dispatch has fired an action to change that.
What is the expected behavior?
I expect that when dispatch is called useSelector should pick up the latest changes.
Please note that this was all working perfectly until recently when I noticed that the useSelector hook is no longer firing.
Which browser and OS are affected by this issue?
All browsers
Did this work in previous versions of React Redux?
- Yes
Metadata
Metadata
Assignees
Labels
No labels