sx prop triggers re-render
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 99.1k
- Forks
- 32.5k
- Avg merge
- 2d 17h
- Merged PRs (30d)
- 106
Description
In Version 9 a lot of system props we used got removed. And (according to the upgrade guide) sx seems to be the new way to go. But wouldn't adding an inline object to the sx prop trigger a re-render on child components every time. Even when the children are pure. We have a large codebase with tousands of components and a lot of lists and deep structures. Are we now forced to use useMemo or create stable objects for each and every sx prop?
Search keywords:
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the upgrade guide's sx section and the issue's inline-object re-render question. Determine whether inline sx objects affect pure child components and whether stable objects are required; done means providing a concrete, documented answer for large lists and deep component trees.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- frontend
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 38/100