22 lines
466 B
TypeScript
Raw Normal View History

2019-09-25 17:26:19 +09:00
import { Selector, createSelector } from '@ngrx/store';
import { UserInfo } from '@ucap-webmessenger/protocol-sync';
export interface State {
buddyInfoList: UserInfo[];
buddy2SyncDate: string;
}
export const initialState: State = {
buddyInfoList: [],
buddy2SyncDate: ''
};
export function selectors<S>(selector: Selector<any, State>) {
return {
buddyInfoList: createSelector(
selector,
(state: State) => state.buddyInfoList
)
};
}