import { createSelector, createFeatureSelector, } from '@ngrx/store'; import { MODULE } from '../sensor.constant'; import * as SensorEntityStore from './entity/sensor'; import * as SensorListContainerStore from './container/sensor-list'; export interface State { sensor_list: SensorListContainerStore.State; } export const REDUCERS = { sensor: SensorListContainerStore.reducer, }; export const EFFECTS = [ SensorEntityStore.Effects, ]; export const selectState = createFeatureSelector(MODULE.name); export const SensorEntitySelector = SensorListContainerStore.getSelectors(createSelector( selectState, (state: State) => state.sensor_list )); export const SensorPageSelector = createSelector( selectState, (state: State) => state.sensor_list.page );