Skip to content
William Horn edited this page Jul 23, 2019 · 6 revisions

Getting data from the store

State

export interface FiltersState {
  dateRange: DateRangeState;
  ...more properties
}

Example Selector

export const getDateRange = createSelector(
  getFiltersState,
  (state: FiltersState) => state.dateRange
);

Using the selector

const dateRange$: Observable<Date> = this.store$.select(filterStore.getDateRange);
Clone this wiki locally