reselect icon indicating copy to clipboard operation
reselect copied to clipboard

Question: Mixing selectors with mapStateToProps?

Open tristangodfrey opened this issue 10 years ago • 1 comments

Should/can I mix selectors with standard mappings?

So something like this:

   const mapStateToProps = (state) => {
      return {
         loading: state.loading,
         currentRank: currentRankSelector(state),
      }
   }

As far as I understand selectors are purely for computing derived data, so it doesn't make sense to use selectors for raw state right?

tristangodfrey avatar Feb 18 '16 12:02 tristangodfrey

Right. Your code sample looks good to me.

ellbee avatar Feb 18 '16 19:02 ellbee