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.

Wrap all nodes and marks in default shouldComponentUpdate

See original GitHub issue

Right now it’s only being applied to the default renderers, but there’s a good chance that people don’t implement them for custom renderers (the examples are a good example of omitting this) and it slows things down a lot. Instead, it might be nice to have them wrapped by default with a component with the proper shouldComponentUpdate, but then to allow for defining your own with a static property on the component like suppressShouldComponentUpdate or similar.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
ianstormtaylorcommented, Jul 26, 2016

Done now by default for nodes!

1reaction
aeneasrcommented, Jul 21, 2016

Ah right, thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to use shouldComponentUpdate with React Hooks?
In the first link it says (https://reactjs.org/docs/hooks-faq.html#from-classes-to-hooks):. shouldComponentUpdate: See React.memo.
Read more >
React Top-Level API
Unlike the shouldComponentUpdate() method on class components, the areEqual function returns true if the props are equal and false if the props are...
Read more >
shouldComponentUpdate implementation in React ...
According to PureComponent Documentation it only does a shallow comparison in shouldComponentUpdate() . Hence, if all your props are wrapped in an object...
Read more >
A (Mostly) Complete Guide to React Rendering Behavior
The wrapper component's default behavior is to check to see if any of the props have changed, and if not, prevent a re-render....
Read more >
04_FrontEndLibraries_React.md - gists · GitHub
This one parent element would wrap all of the other levels of nested elements. ... getElementById() to select the DOM node to render...
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