cantierecreativo/redux-bees

Any repercussions of accessing state directly?

Opened this issue · 1 comments

The docs say to use redux-bees state selectors but for a case when all we want to do is check if an entity exists in state, is there any issue checking in state without a selector?

Generally you want to prefer selectors over direct access because a future release may make changes to the structure of the redux state. I'd recommend implementing your own selector function instead of doing the direct access in your mapStateToProps, that way if the data structure changes, you only have one place in your code that needs fixing.