Skip to content

Commit

Permalink
reselect libdef: Convert object types to exact, or explicitly inexact.
Browse files Browse the repository at this point in the history
An instance of zulip#3452.
  • Loading branch information
chrisbobbe authored and gnprice committed Jul 2, 2021
1 parent ee52852 commit f89b976
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions flow-typed/reselect_v3.x.x.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ declare module "reselect" {

declare type OutputSelector<-TState, TProps, TResult> =
& InputSelector<TState, TProps, TResult>
& {
& {|
recomputations(): number,
resetRecomputations(): number,
resultFunc(...args: any[]): TResult,
};
|};

declare type SelectorCreator = {
<TState, TProps, TResult, T1>(
Expand Down Expand Up @@ -869,10 +869,11 @@ declare module "reselect" {
arg15: T15,
arg16: T16
) => TResult
): OutputSelector<TState, TProps, TResult>
): OutputSelector<TState, TProps, TResult>,
...
};

declare type Reselect = {
declare type Reselect = {|
createSelector: SelectorCreator,

defaultMemoize: <TFunc: Function>(
Expand All @@ -885,11 +886,11 @@ declare module "reselect" {
...memoizeOptions: any[]
) => SelectorCreator,

createStructuredSelector: <TState, TProps, InputSelectors: {[k: string | number]: InputSelector<TState, TProps, any>}>(
createStructuredSelector: <TState, TProps, InputSelectors: {|[k: string | number]: InputSelector<TState, TProps, any>|}>(
inputSelectors: InputSelectors,
selectorCreator?: SelectorCreator
) => OutputSelector<TState, TProps, $ObjMap<InputSelectors, ExtractReturnType>>
};
|};

declare module.exports: Reselect;
}

0 comments on commit f89b976

Please sign in to comment.