-
-
Save martinschnurer/1b83be39efabf7d180ceb079cb8a702c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// this selector now returns values wrapped in the object | |
// so you would need to write equality checkers as the second argument in the useSelector function | |
const usersCountObj = useSelector(state => { | |
return { | |
users: state.users, | |
userCount: state.users.length | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment