import { IStoreState } from '@opencrvs/client/src/store' ; import { IRejectState } from '@opencrvs/client/src/review/reducer' ; const getPartialState = ( store ) : IRejectState => store . reject ; function getKey < K extends keyof IRejectState > ( store , key ) { return getPartialState ( store ) [ key ] ; } export const getRejectForm = ( store ) : IRejectState [ 'rejectForm' ] => getKey ( store , 'rejectForm' ) ;