// flow-typed signature: 86993bd000012d3e1ef10d757d16952d // flow-typed version: a165222d28/redux_v3.x.x/flow_>=v0.33.x declare module 'redux' { /* S = State A = Action D = Dispatch */ declare type DispatchAPI = (action: A) => A; declare type Dispatch }> = DispatchAPI; declare type MiddlewareAPI> = { dispatch: D; getState(): S; }; declare type Store> = { // rewrite MiddlewareAPI members in order to get nicer error messages (intersections produce long messages) dispatch: D; getState(): S; subscribe(listener: () => void): () => void; replaceReducer(nextReducer: Reducer): void }; declare type Reducer = (state: S, action: A) => S; declare type CombinedReducer = (state: $Shape & {} | void, action: A) => S; declare type Middleware> = (api: MiddlewareAPI) => (next: D) => D; declare type StoreCreator> = { (reducer: Reducer, enhancer?: StoreEnhancer): Store; (reducer: Reducer, preloadedState: S, enhancer?: StoreEnhancer): Store; }; declare type StoreEnhancer> = (next: StoreCreator) => StoreCreator; declare function createStore(reducer: Reducer, enhancer?: StoreEnhancer): Store; declare function createStore(reducer: Reducer, preloadedState: S, enhancer?: StoreEnhancer): Store; declare function applyMiddleware(...middlewares: Array>): StoreEnhancer; declare type ActionCreator = (...args: Array) => A; declare type ActionCreators = { [key: K]: ActionCreator }; declare function bindActionCreators, D: DispatchAPI>(actionCreator: C, dispatch: D): C; declare function bindActionCreators, D: DispatchAPI>(actionCreators: C, dispatch: D): C; declare function combineReducers(reducers: O): CombinedReducer<$ObjMap(r: Reducer) => S>, A>; declare function compose(ab: (a: A) => B): (a: A) => B declare function compose( bc: (b: B) => C, ab: (a: A) => B ): (a: A) => C declare function compose( cd: (c: C) => D, bc: (b: B) => C, ab: (a: A) => B ): (a: A) => D declare function compose( de: (d: D) => E, cd: (c: C) => D, bc: (b: B) => C, ab: (a: A) => B ): (a: A) => E declare function compose( ef: (e: E) => F, de: (d: D) => E, cd: (c: C) => D, bc: (b: B) => C, ab: (a: A) => B ): (a: A) => F declare function compose( fg: (f: F) => G, ef: (e: E) => F, de: (d: D) => E, cd: (c: C) => D, bc: (b: B) => C, ab: (a: A) => B ): (a: A) => G declare function compose( gh: (g: G) => H, fg: (f: F) => G, ef: (e: E) => F, de: (d: D) => E, cd: (c: C) => D, bc: (b: B) => C, ab: (a: A) => B ): (a: A) => H declare function compose( hi: (h: H) => I, gh: (g: G) => H, fg: (f: F) => G, ef: (e: E) => F, de: (d: D) => E, cd: (c: C) => D, bc: (b: B) => C, ab: (a: A) => B ): (a: A) => I }