container store

This commit is contained in:
insanity
2018-05-25 21:52:50 +09:00
parent f004270fbe
commit 67a924bcf1
2 changed files with 15 additions and 4 deletions

View File

@@ -1,7 +1,15 @@
import { Selector, createSelector } from '@ngrx/store';
import { createEntityAdapter, EntityState } from '@loafer/ng-entity';
export interface State {
pending: boolean;
}
export const initialState: State = {
pending: false,
};
export function getSelectors<S>(selector: Selector<any, State>) {
return {
selectPending: createSelector(selector, (state: State) => state.pending),
};
}