1 | import { InjectionToken } from '@angular/core';
|
2 | import { Action, ActionReducer, ActionReducerMap, ActionReducerFactory, StoreFeature, InitialState, MetaReducer, RuntimeChecks } from './models';
|
3 | import { combineReducers } from './utils';
|
4 | export interface StoreConfig<T, V extends Action = Action> {
|
5 | initialState?: InitialState<T>;
|
6 | reducerFactory?: ActionReducerFactory<T, V>;
|
7 | metaReducers?: MetaReducer<{
|
8 | [P in keyof T]: T[P];
|
9 | }, V>[];
|
10 | }
|
11 | export interface RootStoreConfig<T, V extends Action = Action> extends StoreConfig<T, V> {
|
12 | runtimeChecks?: Partial<RuntimeChecks>;
|
13 | }
|
14 |
|
15 |
|
16 |
|
17 | export interface FeatureSlice<T, V extends Action = Action> {
|
18 | name: string;
|
19 | reducer: ActionReducer<T, V>;
|
20 | }
|
21 | export declare function _createStoreReducers<T, V extends Action = Action>(reducers: ActionReducerMap<T, V> | InjectionToken<ActionReducerMap<T, V>>): ActionReducerMap<T, V>;
|
22 | export declare function _createFeatureStore<T, V extends Action = Action>(configs: StoreConfig<T, V>[] | InjectionToken<StoreConfig<T, V>>[], featureStores: StoreFeature<T, V>[]): (StoreFeature<T, V> | {
|
23 | key: string;
|
24 | reducerFactory: ActionReducerFactory<T, V> | typeof combineReducers;
|
25 | metaReducers: MetaReducer<{ [P in keyof T]: T[P]; }, V>[];
|
26 | initialState: InitialState<T> | undefined;
|
27 | })[];
|
28 | export declare function _createFeatureReducers<T, V extends Action = Action>(reducerCollection: Array<ActionReducerMap<T, V> | InjectionToken<ActionReducerMap<T, V>>>): ActionReducerMap<T, V>[];
|
29 | export declare function _initialStateFactory(initialState: any): any;
|
30 | export declare function _concatMetaReducers(metaReducers: MetaReducer[], userProvidedMetaReducers: MetaReducer[]): MetaReducer[];
|
31 | export declare function _provideForRootGuard(): unknown;
|