Files
codecrumbs/example-project/auth/selectors.js
2018-10-25 19:48:13 +02:00

17 lines
320 B
JavaScript

import { createSelector } from 'reselect';
export function isAuthenticated(state) {
return getAuth(state).authenticated;
}
//=====================================
// MEMOIZED SELECTORS
//-------------------------------------
export const getAuth = createSelector(
state => state.auth,
auth => auth.toJS()
);