1 | import { NormalizedCache } from './data/store';
|
2 | import { QueryStore } from './queries/store';
|
3 | import { MutationStore } from './mutations/store';
|
4 | import { OptimisticStore } from './optimistic-data/store';
|
5 | import { ApolloAction } from './actions';
|
6 | import { IdGetter } from './data/extensions';
|
7 | import { MutationBehaviorReducerMap } from './data/mutationResults';
|
8 | export interface Store {
|
9 | data: NormalizedCache;
|
10 | queries: QueryStore;
|
11 | mutations: MutationStore;
|
12 | optimistic: OptimisticStore;
|
13 | }
|
14 | export interface ApolloStore {
|
15 | dispatch: (action: ApolloAction) => void;
|
16 | getState: () => any;
|
17 | }
|
18 | export declare function createApolloReducer(config: ApolloReducerConfig): Function;
|
19 | export declare function createApolloStore({reduxRootKey, initialState, config, reportCrashes}?: {
|
20 | reduxRootKey?: string;
|
21 | initialState?: any;
|
22 | config?: ApolloReducerConfig;
|
23 | reportCrashes?: boolean;
|
24 | }): ApolloStore;
|
25 | export interface ApolloReducerConfig {
|
26 | dataIdFromObject?: IdGetter;
|
27 | mutationBehaviorReducers?: MutationBehaviorReducerMap;
|
28 | }
|
29 | export declare function getDataWithOptimisticResults(store: Store): NormalizedCache;
|