mapStateToProps not always called after upgrading to 5.0.1
See original GitHub issueI have a boolean value inside a reducer and the mapStateToProps
is not always called when the value changes.
Here’s the log from 4.4.6:
[mapStateToProps] showResults false
[reducer] previous value: false ; new value: true
[mapStateToProps] showResults true
[reducer] previous value: true ; new value: false
[mapStateToProps] showResults false
But here’s the one from 5.0.1:
[mapStateToProps] showResults false
[reducer] previous value: false ; new value: true
[mapStateToProps] showResults true
[reducer] previous value: true ; new value: false
[reducer] previous value: false ; new value: false
Issue Analytics
- State:
- Created 7 years ago
- Comments:9 (9 by maintainers)
Top Results From Across the Web
MapStateToProps not being called after changing STATE in ...
So you can see the action is happening and the reducer state is updating, but there is not update in component side !...
Read more >Connect | React Redux
If your mapStateToProps function is declared as taking two parameters, it will be called whenever the store state changes or when the ...
Read more >Your First Immutable React & Redux App - ReactJS News
I'd like to make everything seem as simple as possible so that you can wrap your head around it. After all, how hard...
Read more >react-redux: Versions - Openbase
When we migrated React-Redux to TS, we copied over all of the types from that package as a ... mapStateToProps not always called...
Read more >react-redux Getting started with react-redux - RIP Tutorial
React components aware of the Redux store are called... ... Since all container componenents need to access the Redux store, ... 5.0.1, 2016-12-14....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yep. Just submitted PR #584 to fix this use case.
@jimbolla : I’d say that if we can fix it without much hassle, then we might as well go ahead and do so. Sounds like it’s “just” a matter of adding a couple more entries to context, right?