1 | import * as React from 'react';
|
2 | import { MemoExoticComponent, ForwardRefExoticComponent, Context, ReactNode, ComponentType, ComponentClass, ClassAttributes, JSX, FunctionComponent } from 'react';
|
3 | import { Action, UnknownAction, Store, Dispatch } from 'redux';
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 | declare const REACT_STATICS: {
|
11 | readonly childContextTypes: true;
|
12 | readonly contextType: true;
|
13 | readonly contextTypes: true;
|
14 | readonly defaultProps: true;
|
15 | readonly displayName: true;
|
16 | readonly getDefaultProps: true;
|
17 | readonly getDerivedStateFromError: true;
|
18 | readonly getDerivedStateFromProps: true;
|
19 | readonly mixins: true;
|
20 | readonly propTypes: true;
|
21 | readonly type: true;
|
22 | };
|
23 | declare const KNOWN_STATICS: {
|
24 | readonly name: true;
|
25 | readonly length: true;
|
26 | readonly prototype: true;
|
27 | readonly caller: true;
|
28 | readonly callee: true;
|
29 | readonly arguments: true;
|
30 | readonly arity: true;
|
31 | };
|
32 | declare const FORWARD_REF_STATICS: {
|
33 | readonly $$typeof: true;
|
34 | readonly render: true;
|
35 | readonly defaultProps: true;
|
36 | readonly displayName: true;
|
37 | readonly propTypes: true;
|
38 | };
|
39 | declare const MEMO_STATICS: {
|
40 | readonly $$typeof: true;
|
41 | readonly compare: true;
|
42 | readonly defaultProps: true;
|
43 | readonly displayName: true;
|
44 | readonly propTypes: true;
|
45 | readonly type: true;
|
46 | };
|
47 | type NonReactStatics<Source, C extends {
|
48 | [key: string]: true;
|
49 | } = {}> = {
|
50 | [key in Exclude<keyof Source, Source extends MemoExoticComponent<any> ? keyof typeof MEMO_STATICS | keyof C : Source extends ForwardRefExoticComponent<any> ? keyof typeof FORWARD_REF_STATICS | keyof C : keyof typeof REACT_STATICS | keyof typeof KNOWN_STATICS | keyof C>]: Source[key];
|
51 | };
|
52 |
|
53 | type VoidFunc = () => void;
|
54 | type Listener = {
|
55 | callback: VoidFunc;
|
56 | next: Listener | null;
|
57 | prev: Listener | null;
|
58 | };
|
59 | declare function createListenerCollection(): {
|
60 | clear(): void;
|
61 | notify(): void;
|
62 | get(): Listener[];
|
63 | subscribe(callback: () => void): () => void;
|
64 | };
|
65 | type ListenerCollection = ReturnType<typeof createListenerCollection>;
|
66 | interface Subscription {
|
67 | addNestedSub: (listener: VoidFunc) => VoidFunc;
|
68 | notifyNestedSubs: VoidFunc;
|
69 | handleChangeWrapper: VoidFunc;
|
70 | isSubscribed: () => boolean;
|
71 | onStateChange?: VoidFunc | null;
|
72 | trySubscribe: VoidFunc;
|
73 | tryUnsubscribe: VoidFunc;
|
74 | getListeners: () => ListenerCollection;
|
75 | }
|
76 |
|
77 | interface ProviderProps<A extends Action<string> = UnknownAction, S = unknown> {
|
78 | |
79 |
|
80 |
|
81 | store: Store<S, A>;
|
82 | |
83 |
|
84 |
|
85 | serverState?: S;
|
86 | |
87 |
|
88 |
|
89 |
|
90 |
|
91 |
|
92 | context?: Context<ReactReduxContextValue<S, A> | null>;
|
93 | |
94 |
|
95 |
|
96 |
|
97 |
|
98 |
|
99 |
|
100 |
|
101 | stabilityCheck?: DevModeCheckFrequency;
|
102 | |
103 |
|
104 |
|
105 |
|
106 |
|
107 |
|
108 |
|
109 |
|
110 |
|
111 |
|
112 | identityFunctionCheck?: DevModeCheckFrequency;
|
113 | children: ReactNode;
|
114 | }
|
115 | declare function Provider<A extends Action<string> = UnknownAction, S = unknown>(providerProps: ProviderProps<A, S>): React.JSX.Element;
|
116 |
|
117 | interface ReactReduxContextValue<SS = any, A extends Action<string> = UnknownAction> extends Pick<ProviderProps, 'stabilityCheck' | 'identityFunctionCheck'> {
|
118 | store: Store<SS, A>;
|
119 | subscription: Subscription;
|
120 | getServerState?: () => SS;
|
121 | }
|
122 | declare const ReactReduxContext: Context<ReactReduxContextValue<any, UnknownAction> | null>;
|
123 | type ReactReduxContextInstance = typeof ReactReduxContext;
|
124 |
|
125 |
|
126 |
|
127 |
|
128 |
|
129 |
|
130 |
|
131 | type DevModeCheckFrequency = 'never' | 'once' | 'always';
|
132 |
|
133 |
|
134 |
|
135 |
|
136 |
|
137 |
|
138 | interface DevModeChecks {
|
139 | |
140 |
|
141 |
|
142 |
|
143 |
|
144 |
|
145 |
|
146 |
|
147 |
|
148 |
|
149 | stabilityCheck: DevModeCheckFrequency;
|
150 | |
151 |
|
152 |
|
153 |
|
154 |
|
155 |
|
156 |
|
157 |
|
158 |
|
159 |
|
160 |
|
161 |
|
162 | identityFunctionCheck: DevModeCheckFrequency;
|
163 | }
|
164 | interface UseSelectorOptions<Selected = unknown> {
|
165 | equalityFn?: EqualityFn<Selected>;
|
166 | |
167 |
|
168 |
|
169 |
|
170 |
|
171 |
|
172 |
|
173 | devModeChecks?: Partial<DevModeChecks>;
|
174 | }
|
175 |
|
176 |
|
177 |
|
178 |
|
179 |
|
180 |
|
181 |
|
182 |
|
183 |
|
184 |
|
185 |
|
186 | interface UseSelector<StateType = unknown> {
|
187 | |
188 |
|
189 |
|
190 |
|
191 |
|
192 |
|
193 |
|
194 |
|
195 |
|
196 |
|
197 |
|
198 |
|
199 | <TState extends StateType = StateType, Selected = unknown>(selector: (state: TState) => Selected, equalityFnOrOptions?: EqualityFn<Selected> | UseSelectorOptions<Selected>): Selected;
|
200 | /**
|
201 | * Creates a "pre-typed" version of {@linkcode useSelector useSelector}
|
202 | * where the `state` type is predefined.
|
203 | *
|
204 | * This allows you to set the `state` type once, eliminating the need to
|
205 | * specify it with every {@linkcode useSelector useSelector} call.
|
206 | *
|
207 | * @returns A pre-typed `useSelector` with the state type already defined.
|
208 | *
|
209 | * @example
|
210 | * ```ts
|
211 | * export const useAppSelector = useSelector.withTypes<RootState>()
|
212 | * ```
|
213 | *
|
214 | * @template OverrideStateType - The specific type of state this hook operates on.
|
215 | *
|
216 | * @since 9.1.0
|
217 | */
|
218 | withTypes: <OverrideStateType extends StateType>() => UseSelector<OverrideStateType>;
|
219 | }
|
220 |
|
221 |
|
222 |
|
223 |
|
224 |
|
225 |
|
226 | declare function createSelectorHook(context?: React.Context<ReactReduxContextValue<any, any> | null>): UseSelector;
|
227 |
|
228 |
|
229 |
|
230 |
|
231 |
|
232 |
|
233 |
|
234 |
|
235 |
|
236 |
|
237 |
|
238 |
|
239 |
|
240 |
|
241 |
|
242 |
|
243 |
|
244 |
|
245 |
|
246 |
|
247 |
|
248 |
|
249 |
|
250 | declare const useSelector: UseSelector<unknown>;
|
251 |
|
252 | type FixTypeLater = any;
|
253 | type EqualityFn<T> = (a: T, b: T) => boolean;
|
254 | type ExtendedEqualityFn<T, P> = (a: T, b: T, c: P, d: P) => boolean;
|
255 | type AnyIfEmpty<T extends object> = keyof T extends never ? any : T;
|
256 | type DistributiveOmit<T, K extends keyof T> = T extends unknown ? Omit<T, K> : never;
|
257 | interface DispatchProp<A extends Action<string> = UnknownAction> {
|
258 | dispatch: Dispatch<A>;
|
259 | }
|
260 |
|
261 |
|
262 |
|
263 |
|
264 |
|
265 |
|
266 |
|
267 |
|
268 |
|
269 |
|
270 |
|
271 |
|
272 | type Matching<InjectedProps, DecorationTargetProps> = {
|
273 | [P in keyof DecorationTargetProps]: P extends keyof InjectedProps ? InjectedProps[P] extends DecorationTargetProps[P] ? DecorationTargetProps[P] : InjectedProps[P] : DecorationTargetProps[P];
|
274 | };
|
275 |
|
276 |
|
277 |
|
278 |
|
279 |
|
280 |
|
281 |
|
282 |
|
283 |
|
284 |
|
285 | type Shared<InjectedProps, DecorationTargetProps> = {
|
286 | [P in Extract<keyof InjectedProps, keyof DecorationTargetProps>]?: InjectedProps[P] extends DecorationTargetProps[P] ? DecorationTargetProps[P] : never;
|
287 | };
|
288 | type GetProps<C> = C extends ComponentType<infer P> ? C extends ComponentClass<P> ? ClassAttributes<InstanceType<C>> & P : P : never;
|
289 | type GetLibraryManagedProps<C> = JSX.LibraryManagedAttributes<C, GetProps<C>>;
|
290 | type ConnectedComponent<C extends ComponentType<any>, P> = FunctionComponent<P> & NonReactStatics<C> & {
|
291 | WrappedComponent: C;
|
292 | };
|
293 | type ConnectPropsMaybeWithoutContext<TActualOwnProps> = TActualOwnProps extends {
|
294 | context: any;
|
295 | } ? Omit<ConnectProps, 'context'> : ConnectProps;
|
296 | type Identity<T> = T;
|
297 | type Mapped<T> = Identity<{
|
298 | [k in keyof T]: T[k];
|
299 | }>;
|
300 | type InferableComponentEnhancerWithProps<TInjectedProps, TNeedsProps> = <C extends ComponentType<Matching<TInjectedProps, GetProps<C>>>>(component: C) => ConnectedComponent<C, Mapped<DistributiveOmit<GetLibraryManagedProps<C>, keyof Shared<TInjectedProps, GetLibraryManagedProps<C>>> & TNeedsProps & ConnectPropsMaybeWithoutContext<TNeedsProps & GetProps<C>>>>;
|
301 | type InferableComponentEnhancer<TInjectedProps> = InferableComponentEnhancerWithProps<TInjectedProps, {}>;
|
302 | type InferThunkActionCreatorType<TActionCreator extends (...args: any[]) => any> = TActionCreator extends (...args: infer TParams) => (...args: any[]) => infer TReturn ? (...args: TParams) => TReturn : TActionCreator;
|
303 | type HandleThunkActionCreator<TActionCreator> = TActionCreator extends (...args: any[]) => any ? InferThunkActionCreatorType<TActionCreator> : TActionCreator;
|
304 | type ResolveThunks<TDispatchProps> = TDispatchProps extends {
|
305 | [key: string]: any;
|
306 | } ? {
|
307 | [C in keyof TDispatchProps]: HandleThunkActionCreator<TDispatchProps[C]>;
|
308 | } : TDispatchProps;
|
309 |
|
310 |
|
311 |
|
312 |
|
313 |
|
314 |
|
315 |
|
316 |
|
317 |
|
318 |
|
319 |
|
320 |
|
321 | interface TypedUseSelectorHook<TState> {
|
322 | <TSelected>(selector: (state: TState) => TSelected, equalityFn?: EqualityFn<NoInfer<TSelected>>): TSelected;
|
323 | <Selected = unknown>(selector: (state: TState) => Selected, options?: UseSelectorOptions<Selected>): Selected;
|
324 | }
|
325 | type NoInfer<T> = [T][T extends any ? 0 : never];
|
326 |
|
327 | type SelectorFactory<S, TProps, TOwnProps, TFactoryOptions> = (dispatch: Dispatch<Action<string>>, factoryOptions: TFactoryOptions) => Selector<S, TProps, TOwnProps>;
|
328 | type Selector<S, TProps, TOwnProps = null> = TOwnProps extends null | undefined ? (state: S) => TProps : (state: S, ownProps: TOwnProps) => TProps;
|
329 | type MapStateToProps<TStateProps, TOwnProps, State> = (state: State, ownProps: TOwnProps) => TStateProps;
|
330 | type MapStateToPropsFactory<TStateProps, TOwnProps, State> = (initialState: State, ownProps: TOwnProps) => MapStateToProps<TStateProps, TOwnProps, State>;
|
331 | type MapStateToPropsParam<TStateProps, TOwnProps, State> = MapStateToPropsFactory<TStateProps, TOwnProps, State> | MapStateToProps<TStateProps, TOwnProps, State> | null | undefined;
|
332 | type MapDispatchToPropsFunction<TDispatchProps, TOwnProps> = (dispatch: Dispatch<Action<string>>, ownProps: TOwnProps) => TDispatchProps;
|
333 | type MapDispatchToProps<TDispatchProps, TOwnProps> = MapDispatchToPropsFunction<TDispatchProps, TOwnProps> | TDispatchProps;
|
334 | type MapDispatchToPropsFactory<TDispatchProps, TOwnProps> = (dispatch: Dispatch<Action<string>>, ownProps: TOwnProps) => MapDispatchToPropsFunction<TDispatchProps, TOwnProps>;
|
335 | type MapDispatchToPropsParam<TDispatchProps, TOwnProps> = MapDispatchToPropsFactory<TDispatchProps, TOwnProps> | MapDispatchToProps<TDispatchProps, TOwnProps>;
|
336 | type MapDispatchToPropsNonObject<TDispatchProps, TOwnProps> = MapDispatchToPropsFactory<TDispatchProps, TOwnProps> | MapDispatchToPropsFunction<TDispatchProps, TOwnProps>;
|
337 | type MergeProps<TStateProps, TDispatchProps, TOwnProps, TMergedProps> = (stateProps: TStateProps, dispatchProps: TDispatchProps, ownProps: TOwnProps) => TMergedProps;
|
338 |
|
339 | interface ConnectProps {
|
340 |
|
341 | context?: ReactReduxContextInstance;
|
342 |
|
343 | store?: Store;
|
344 | }
|
345 |
|
346 |
|
347 |
|
348 | type ConnectedProps<TConnector> = TConnector extends InferableComponentEnhancerWithProps<infer TInjectedProps, any> ? unknown extends TInjectedProps ? TConnector extends InferableComponentEnhancer<infer TInjectedProps> ? TInjectedProps : never : TInjectedProps : never;
|
349 | interface ConnectOptions<State = unknown, TStateProps = {}, TOwnProps = {}, TMergedProps = {}> {
|
350 | forwardRef?: boolean;
|
351 | context?: typeof ReactReduxContext;
|
352 | areStatesEqual?: (nextState: State, prevState: State, nextOwnProps: TOwnProps, prevOwnProps: TOwnProps) => boolean;
|
353 | areOwnPropsEqual?: (nextOwnProps: TOwnProps, prevOwnProps: TOwnProps) => boolean;
|
354 | areStatePropsEqual?: (nextStateProps: TStateProps, prevStateProps: TStateProps) => boolean;
|
355 | areMergedPropsEqual?: (nextMergedProps: TMergedProps, prevMergedProps: TMergedProps) => boolean;
|
356 | }
|
357 |
|
358 |
|
359 |
|
360 |
|
361 |
|
362 |
|
363 |
|
364 |
|
365 |
|
366 |
|
367 |
|
368 |
|
369 |
|
370 |
|
371 |
|
372 |
|
373 |
|
374 |
|
375 |
|
376 | interface Connect<DefaultState = unknown> {
|
377 | (): InferableComponentEnhancer<DispatchProp>;
|
378 |
|
379 | <TStateProps = {}, no_dispatch = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>): InferableComponentEnhancerWithProps<TStateProps & DispatchProp, TOwnProps>;
|
380 |
|
381 | <no_state = {}, TDispatchProps = {}, TOwnProps = {}>(mapStateToProps: null | undefined, mapDispatchToProps: MapDispatchToPropsNonObject<TDispatchProps, TOwnProps>): InferableComponentEnhancerWithProps<TDispatchProps, TOwnProps>;
|
382 |
|
383 | <no_state = {}, TDispatchProps = {}, TOwnProps = {}>(mapStateToProps: null | undefined, mapDispatchToProps: MapDispatchToPropsParam<TDispatchProps, TOwnProps>): InferableComponentEnhancerWithProps<ResolveThunks<TDispatchProps>, TOwnProps>;
|
384 |
|
385 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: MapDispatchToPropsNonObject<TDispatchProps, TOwnProps>): InferableComponentEnhancerWithProps<TStateProps & TDispatchProps, TOwnProps>;
|
386 |
|
387 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: null | undefined): InferableComponentEnhancerWithProps<TStateProps, TOwnProps>;
|
388 |
|
389 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: MapDispatchToPropsParam<TDispatchProps, TOwnProps>): InferableComponentEnhancerWithProps<TStateProps & ResolveThunks<TDispatchProps>, TOwnProps>;
|
390 |
|
391 | <no_state = {}, no_dispatch = {}, TOwnProps = {}, TMergedProps = {}>(mapStateToProps: null | undefined, mapDispatchToProps: null | undefined, mergeProps: MergeProps<undefined, DispatchProp, TOwnProps, TMergedProps>): InferableComponentEnhancerWithProps<TMergedProps, TOwnProps>;
|
392 |
|
393 | <TStateProps = {}, no_dispatch = {}, TOwnProps = {}, TMergedProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: null | undefined, mergeProps: MergeProps<TStateProps, DispatchProp, TOwnProps, TMergedProps>): InferableComponentEnhancerWithProps<TMergedProps, TOwnProps>;
|
394 |
|
395 | <no_state = {}, TDispatchProps = {}, TOwnProps = {}, TMergedProps = {}>(mapStateToProps: null | undefined, mapDispatchToProps: MapDispatchToPropsParam<TDispatchProps, TOwnProps>, mergeProps: MergeProps<undefined, TDispatchProps, TOwnProps, TMergedProps>): InferableComponentEnhancerWithProps<TMergedProps, TOwnProps>;
|
396 |
|
397 | <TStateProps = {}, no_dispatch = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: null | undefined, mergeProps: null | undefined, options: ConnectOptions<State, TStateProps, TOwnProps>): InferableComponentEnhancerWithProps<DispatchProp & TStateProps, TOwnProps>;
|
398 |
|
399 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}>(mapStateToProps: null | undefined, mapDispatchToProps: MapDispatchToPropsNonObject<TDispatchProps, TOwnProps>, mergeProps: null | undefined, options: ConnectOptions<{}, TStateProps, TOwnProps>): InferableComponentEnhancerWithProps<TDispatchProps, TOwnProps>;
|
400 |
|
401 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}>(mapStateToProps: null | undefined, mapDispatchToProps: MapDispatchToPropsParam<TDispatchProps, TOwnProps>, mergeProps: null | undefined, options: ConnectOptions<{}, TStateProps, TOwnProps>): InferableComponentEnhancerWithProps<ResolveThunks<TDispatchProps>, TOwnProps>;
|
402 |
|
403 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: MapDispatchToPropsNonObject<TDispatchProps, TOwnProps>, mergeProps: null | undefined, options: ConnectOptions<State, TStateProps, TOwnProps>): InferableComponentEnhancerWithProps<TStateProps & TDispatchProps, TOwnProps>;
|
404 |
|
405 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: MapDispatchToPropsParam<TDispatchProps, TOwnProps>, mergeProps: null | undefined, options: ConnectOptions<State, TStateProps, TOwnProps>): InferableComponentEnhancerWithProps<TStateProps & ResolveThunks<TDispatchProps>, TOwnProps>;
|
406 |
|
407 | <TStateProps = {}, TDispatchProps = {}, TOwnProps = {}, TMergedProps = {}, State = DefaultState>(mapStateToProps: MapStateToPropsParam<TStateProps, TOwnProps, State>, mapDispatchToProps: MapDispatchToPropsParam<TDispatchProps, TOwnProps>, mergeProps: MergeProps<TStateProps, TDispatchProps, TOwnProps, TMergedProps>, options?: ConnectOptions<State, TStateProps, TOwnProps, TMergedProps>): InferableComponentEnhancerWithProps<TMergedProps, TOwnProps>;
|
408 | }
|
409 | declare const _default: Connect;
|
410 |
|
411 | declare function shallowEqual(objA: any, objB: any): boolean;
|
412 |
|
413 | declare function defaultNoopBatch(callback: () => void): void;
|
414 |
|
415 |
|
416 |
|
417 |
|
418 |
|
419 |
|
420 |
|
421 |
|
422 |
|
423 |
|
424 | interface UseDispatch<DispatchType extends Dispatch<UnknownAction> = Dispatch<UnknownAction>> {
|
425 | |
426 |
|
427 |
|
428 |
|
429 |
|
430 |
|
431 |
|
432 | <AppDispatch extends DispatchType = DispatchType>(): AppDispatch;
|
433 | |
434 |
|
435 |
|
436 |
|
437 |
|
438 |
|
439 |
|
440 |
|
441 |
|
442 |
|
443 |
|
444 |
|
445 |
|
446 |
|
447 |
|
448 |
|
449 |
|
450 |
|
451 | withTypes: <OverrideDispatchType extends DispatchType>() => UseDispatch<OverrideDispatchType>;
|
452 | }
|
453 |
|
454 |
|
455 |
|
456 |
|
457 |
|
458 |
|
459 | declare function createDispatchHook<StateType = unknown, ActionType extends Action = UnknownAction>(context?: Context<ReactReduxContextValue<StateType, ActionType> | null>): UseDispatch<Dispatch<ActionType>>;
|
460 |
|
461 |
|
462 |
|
463 |
|
464 |
|
465 |
|
466 |
|
467 |
|
468 |
|
469 |
|
470 |
|
471 |
|
472 |
|
473 |
|
474 |
|
475 |
|
476 |
|
477 |
|
478 |
|
479 |
|
480 |
|
481 | declare const useDispatch: UseDispatch<Dispatch<UnknownAction>>;
|
482 |
|
483 |
|
484 |
|
485 |
|
486 |
|
487 |
|
488 |
|
489 |
|
490 |
|
491 | type ExtractStoreActionType<StoreType extends Store> = StoreType extends Store<any, infer ActionType> ? ActionType : never;
|
492 |
|
493 |
|
494 |
|
495 |
|
496 |
|
497 |
|
498 |
|
499 |
|
500 | interface UseStore<StoreType extends Store> {
|
501 | |
502 |
|
503 |
|
504 |
|
505 |
|
506 | (): StoreType;
|
507 | |
508 |
|
509 |
|
510 |
|
511 |
|
512 |
|
513 |
|
514 |
|
515 | <StateType extends ReturnType<StoreType['getState']> = ReturnType<StoreType['getState']>, ActionType extends Action = ExtractStoreActionType<Store>>(): Store<StateType, ActionType>;
|
516 | |
517 |
|
518 |
|
519 |
|
520 |
|
521 |
|
522 |
|
523 |
|
524 |
|
525 |
|
526 |
|
527 |
|
528 |
|
529 |
|
530 |
|
531 |
|
532 |
|
533 |
|
534 | withTypes: <OverrideStoreType extends StoreType>() => UseStore<OverrideStoreType>;
|
535 | }
|
536 |
|
537 |
|
538 |
|
539 |
|
540 |
|
541 |
|
542 | declare function createStoreHook<StateType = unknown, ActionType extends Action = Action>(context?: Context<ReactReduxContextValue<StateType, ActionType> | null>): UseStore<Store<StateType, ActionType>>;
|
543 |
|
544 |
|
545 |
|
546 |
|
547 |
|
548 |
|
549 |
|
550 |
|
551 |
|
552 |
|
553 |
|
554 |
|
555 |
|
556 |
|
557 |
|
558 | declare const useStore: UseStore<Store<unknown, Action, unknown>>;
|
559 |
|
560 |
|
561 |
|
562 |
|
563 |
|
564 | declare const batch: typeof defaultNoopBatch;
|
565 |
|
566 | export { type AnyIfEmpty, type Connect, type ConnectProps, type ConnectPropsMaybeWithoutContext, type ConnectedComponent, type ConnectedProps, type DispatchProp, type DistributiveOmit, type EqualityFn, type ExtendedEqualityFn, type FixTypeLater, type GetLibraryManagedProps, type GetProps, type HandleThunkActionCreator, type InferThunkActionCreatorType, type InferableComponentEnhancer, type InferableComponentEnhancerWithProps, type MapDispatchToProps, type MapDispatchToPropsFactory, type MapDispatchToPropsFunction, type MapDispatchToPropsNonObject, type MapDispatchToPropsParam, type MapStateToProps, type MapStateToPropsFactory, type MapStateToPropsParam, type Mapped, type Matching, type MergeProps, type NoInfer, Provider, type ProviderProps, ReactReduxContext, type ReactReduxContextValue, type ResolveThunks, type Selector, type SelectorFactory, type Shared, type Subscription, type TypedUseSelectorHook, type UseDispatch, type UseSelector, type UseStore, batch, _default as connect, createDispatchHook, createSelectorHook, createStoreHook, shallowEqual, useDispatch, useSelector, useStore };
|