|
1 | | -import Provider from './components/Provider' |
2 | | -import type { ProviderProps } from './components/Provider' |
3 | 1 | import connect from './components/connect' |
4 | | -import type { |
| 2 | +export type { |
5 | 3 | Connect, |
6 | 4 | ConnectProps, |
7 | 5 | ConnectedProps, |
8 | 6 | } from './components/connect' |
9 | | -import type { |
10 | | - SelectorFactory, |
11 | | - Selector, |
12 | | - MapStateToProps, |
13 | | - MapStateToPropsFactory, |
14 | | - MapStateToPropsParam, |
15 | | - MapDispatchToPropsFunction, |
16 | | - MapDispatchToProps, |
17 | | - MapDispatchToPropsFactory, |
18 | | - MapDispatchToPropsParam, |
19 | | - MapDispatchToPropsNonObject, |
20 | | - MergeProps, |
21 | | -} from './connect/selectorFactory' |
22 | | -import { ReactReduxContext } from './components/Context' |
23 | | -import type { ReactReduxContextValue } from './components/Context' |
24 | | - |
25 | | -import { useDispatch, createDispatchHook } from './hooks/useDispatch' |
26 | | -import { useSelector, createSelectorHook } from './hooks/useSelector' |
27 | | -import { useStore, createStoreHook } from './hooks/useStore' |
28 | 7 |
|
29 | 8 | import shallowEqual from './utils/shallowEqual' |
30 | | -import type { Subscription } from './utils/Subscription' |
| 9 | + |
31 | 10 | import { defaultNoopBatch } from './utils/batch' |
32 | 11 |
|
33 | | -export * from './types' |
| 12 | +export { ReactReduxContext } from './components/Context' |
| 13 | +export type { ReactReduxContextValue } from './components/Context' |
| 14 | + |
| 15 | +export type { ProviderProps } from './components/Provider' |
| 16 | +import Provider from './components/Provider' |
| 17 | + |
34 | 18 | export type { |
35 | | - ProviderProps, |
36 | | - SelectorFactory, |
37 | | - Selector, |
38 | | - MapStateToProps, |
39 | | - MapStateToPropsFactory, |
40 | | - MapStateToPropsParam, |
41 | | - Connect, |
42 | | - ConnectProps, |
43 | | - ConnectedProps, |
44 | | - MapDispatchToPropsFunction, |
45 | 19 | MapDispatchToProps, |
46 | 20 | MapDispatchToPropsFactory, |
47 | | - MapDispatchToPropsParam, |
| 21 | + MapDispatchToPropsFunction, |
48 | 22 | MapDispatchToPropsNonObject, |
| 23 | + MapDispatchToPropsParam, |
| 24 | + MapStateToProps, |
| 25 | + MapStateToPropsFactory, |
| 26 | + MapStateToPropsParam, |
49 | 27 | MergeProps, |
50 | | - ReactReduxContextValue, |
51 | | - Subscription, |
52 | | -} |
| 28 | + Selector, |
| 29 | + SelectorFactory, |
| 30 | +} from './connect/selectorFactory' |
| 31 | + |
| 32 | +export { createDispatchHook, useDispatch } from './hooks/useDispatch' |
| 33 | +export type { UseDispatch } from './hooks/useDispatch' |
| 34 | + |
| 35 | +export { createSelectorHook, useSelector } from './hooks/useSelector' |
| 36 | +export type { UseSelector } from './hooks/useSelector' |
| 37 | + |
| 38 | +export { createStoreHook, useStore } from './hooks/useStore' |
| 39 | + |
| 40 | +export type { Subscription } from './utils/Subscription' |
| 41 | + |
| 42 | +export * from './types' |
53 | 43 |
|
54 | 44 | /** |
55 | 45 | * @deprecated As of React 18, batching is enabled by default for ReactDOM and React Native. |
56 | 46 | * This is now a no-op that immediately runs the callback. |
57 | 47 | */ |
58 | 48 | const batch = defaultNoopBatch |
59 | 49 |
|
60 | | -export { |
61 | | - Provider, |
62 | | - ReactReduxContext, |
63 | | - connect, |
64 | | - useDispatch, |
65 | | - createDispatchHook, |
66 | | - useSelector, |
67 | | - createSelectorHook, |
68 | | - useStore, |
69 | | - createStoreHook, |
70 | | - shallowEqual, |
71 | | - batch, |
72 | | -} |
| 50 | +export { Provider, batch, connect, shallowEqual } |
0 commit comments