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
Hey, I have a medium-sized codebase that has around 12 ORM reducers (registered with createReducer) and around 5-6 regular ones. All reducers are merged with combineReducers and I have a periodic action that dispatches every 5 second.
The real selector is slightly different, but this reproducer is still non-working. I changed the selector to return [0] unconditionally because this value is not getting cached.
The periodic action is not related to the ORM, these will return undefined for that but for some reason the selector above will return a new object (inferring that orm.Item was changed?) and my component will re-render.
I tried to debug but I can't figure out what in redux-orm causes react to act as the model was changed (when it was not, the ORM reducers did nothing).
I'll appreciate any help, thank you!
The text was updated successfully, but these errors were encountered:
Avishayy
changed the title
How to redux-orm falsely triggering state change?
How to debug redux-orm falsely triggering state change?
Oct 7, 2021
Hey, I have a medium-sized codebase that has around 12 ORM reducers (registered with
createReducer
) and around 5-6 regular ones. All reducers are merged withcombineReducers
and I have a periodic action that dispatches every 5 second.Here's the selector:
The real selector is slightly different, but this reproducer is still non-working. I changed the selector to return
[0]
unconditionally because this value is not getting cached.The periodic action is not related to the ORM, these will return
undefined
for that but for some reason the selector above will return a new object (inferring thatorm.Item
was changed?) and my component will re-render.I tried to debug but I can't figure out what in redux-orm causes react to act as the model was changed (when it was not, the ORM reducers did nothing).
I'll appreciate any help, thank you!
The text was updated successfully, but these errors were encountered: