Closed
Description
What is the current behavior?
- Open https://codesandbox.io/s/serene-franklin-pjkhu?file=/src/App.js
- Press button
- Inspect console log
We have some confusing logs in console like:
array equals: true
selector value changed
This indicates the return value of useSelector
changes even its equalityFn
returns true
.
What is the expected behavior?
In DisplayValueList
component, the value mustChange
can change on every press, but the next useSelector
should return a constant value because its selector function returns a static array and its equalityFn
is set to an array equal function, the console log should be clean.
When the first useSelector
is removed, the console output is clean as expected, this is even more confusing to me.
Metadata
Metadata
Assignees
Labels
No labels