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
Example of the selector with constructLocalized
selectors: constructLocalized({
items: state => state.items, // gets the items from state
subTotal: new Duck.Selector(selectors =>createSelector( // createSelector from Reselect
selectors.items(state),
items => items.reduce((computedTotal, item) => computedTotal + item.value, 0)
))
})
subTotal here is always being computed instead of returning cached result. The last arguments required for the defaultMemoize in createSelector to compare with current arguments is null in this case.
Example of selector without constructLocalized
selectors: {
items: state => state.items, // gets the items from state
subTotal: new Duck.Selector(selectors =>createSelector( // createSelector from Reselect
selectors.items(state),
items => items.reduce((computedTotal, item) => computedTotal + item.value, 0)
))
}
subTotal here is returned from cache.
I think there is an issue with constructLocalized that is influencing this to happen.
The text was updated successfully, but these errors were encountered:
Example of the selector with constructLocalized
selectors: constructLocalized({
items: state => state.items, // gets the items from state
subTotal: new Duck.Selector(selectors =>createSelector( // createSelector from Reselect
selectors.items(state),
items => items.reduce((computedTotal, item) => computedTotal + item.value, 0)
))
})
subTotal here is always being computed instead of returning cached result. The last arguments required for the defaultMemoize in createSelector to compare with current arguments is null in this case.
Example of selector without constructLocalized
selectors: {
items: state => state.items, // gets the items from state
subTotal: new Duck.Selector(selectors =>createSelector( // createSelector from Reselect
selectors.items(state),
items => items.reduce((computedTotal, item) => computedTotal + item.value, 0)
))
}
subTotal here is returned from cache.
I think there is an issue with constructLocalized that is influencing this to happen.
The text was updated successfully, but these errors were encountered: