Error in 'Using Immutable Data Structures' section of Docs
Do you want to request a feature or report a bug?
- Report a bug.
What is the current behavior?
- In the Optimizing Performance section of the docs, there is a sub-section called Using Immutable Data Structures. At the end there is a sentence "In this case, since a new reference is returned when mutating x, we can safely assume that x has changed."
The sentence should read, if my assumption is correct, "... we can safely assume that x has not changed
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://jsfiddle.net or similar (template: https://jsfiddle.net/84v837e9/).
- The doc in question is posted here: https://facebook.github.io/react/docs/optimizing-performance.html
What is the expected behavior? As described above, "... we can safely assume that x has not changed
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React? N/A
Hello, I'm working on it (first contribution).
Hey @Assitan! Just a heads up, there's already an open PR for this fix: https://github.com/facebook/react/pull/9845
Ok :)
Fixed in https://github.com/facebook/react/pull/9845.