You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The idea is that users sometimes end up writing badly-written selectors that accidentally recalculate the results every time. This is primarily due to badly-written input functions, such as:
createSelector(state=>({foo: state.foo,bar: state.bar}),({ foo, bar })=>({result: foo+bar}))
Since the input function always returns a new object, the output function will always run and return a new reference.
Probably the simplest thing we can do here would be to double-run the input functions twice and verify that the results are shallow equal.