question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[5.1.0-test.1] Connected components don't re render after state update

See original GitHub issue

I gave a first try to the new beta and I can see some problems (unless I should make some changes).

The components that are connected to the store via connect don’t get updated (they don’t re render). While debugging I can see that the function mapStateToProps gets called correctly (and I can see the changes) after the action but the component doesn’t re-render hence it doesn’t show the new values.

I hope it could help

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:52 (41 by maintainers)

github_iconTop GitHub Comments

1reaction
markeriksoncommented, Oct 19, 2018

Hmm. Good point. Let’s see…

Oh hey, you CAN edit release notes after the fact. Okay, will do. Thanks for the notice!

1reaction
timdorrcommented, Jul 18, 2018

@cellog That’s what the pure option does currently, which is enabled by default. We act essentially as a PureComponent already.

Again, the core issue is the misuse of gDSFP. We’re literally doing the first thing the 16.4 blog post says not to do. So, the refactor would be to not do that. We should do something closer to @bvaughn’s subscription example: https://gist.github.com/bvaughn/d569177d70b50b58bff69c3c4a5353f3

Read more comments on GitHub >

github_iconTop Results From Across the Web

Connected component doesn't re-render after store ...
In my case, when the action UPDATE_CURRENT_USER update the avatar image, the navbar avatar doesn't get the new image only after I change...
Read more >
Why Redux Store Changes Don't Re-render - YouTube
When using Redux, it's common to run into issues where your store isn't updating, or isn't updating in the way you expect it...
Read more >
Why React Re-Renders
When a component re-renders, because one of its state variables has been updated, that re-render will cascade all the way down the tree,...
Read more >
A (Mostly) Complete Guide to React Rendering Behavior
If the component infinitely keeps queueing state updates and forcing React to re-render it, React will break the loop after a set number...
Read more >
Introducing and Implementing IBM FlashSystem V9000
After connecting the components in a scalable building block, no physical cable connects any host to any switch in the internal Fibre ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found