File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ import type { NonReactStatics } from 'hoist-non-react-statics'
1010
1111export type FixTypeLater = any
1212
13- export type EqualityFn < T > = ( a : T | undefined , b : T | undefined ) => boolean
13+ export type EqualityFn < T > = ( a : T , b : T ) => boolean
1414
1515/**
1616 * This interface can be augmented by users to add default types for the root state when
@@ -85,6 +85,13 @@ export type GetProps<C> = C extends ComponentType<infer P>
8585 : P
8686 : never
8787
88+ // Applies LibraryManagedAttributes (proper handling of defaultProps
89+ // and propTypes).
90+ export type GetLibraryManagedProps < C > = JSX . LibraryManagedAttributes <
91+ C ,
92+ GetProps < C >
93+ >
94+
8895// Applies LibraryManagedAttributes (proper handling of defaultProps
8996// and propTypes), as well as defines WrappedComponent.
9097export type ConnectedComponent <
@@ -105,7 +112,10 @@ export type InferableComponentEnhancerWithProps<TInjectedProps, TNeedsProps> = <
105112 component : C
106113) => ConnectedComponent <
107114 C ,
108- DistributiveOmit < GetProps < C > , keyof Shared < TInjectedProps , GetProps < C > > > &
115+ DistributiveOmit <
116+ GetLibraryManagedProps < C > ,
117+ keyof Shared < TInjectedProps , GetLibraryManagedProps < C > >
118+ > &
109119 TNeedsProps
110120>
111121
You can’t perform that action at this time.
0 commit comments