import { createSelector } from 'reselect' ; import IRootState from 'models/IRootState' ; export const isLoadingSelector = createSelector ( ( state ) => state . app , ( app ) => app . isLoading ) ; export const userSelector = createSelector ( ( state ) => state . auth , ( auth ) => auth . user ) ; export const roleSelector = createSelector ( ( state ) => state . auth , ( auth ) => auth . role ) ;