We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8b79d3b commit 7b2b7d9Copy full SHA for 7b2b7d9
README.md
@@ -66,3 +66,14 @@ const B = () => {
66
`memo` 只会根据 `props` 判断是否需要重新渲染,和 `state` 和 `context` `无关,state` 或 `context` 发生变化时,组件依然会正常的进行重新渲染
67
68
- `useReducer` 可以优化复杂的 `state`
69
+
70
+- redux 管理全局应用状态(redux 分支)
71
+ 使用步骤:
72
73
+ 1. 引入 redux 核心包
74
+ 2. 创建 reducer 整合函数
75
+ 3. 通过 reducer 对象创建 store
76
+ 4. 对 store 中的 state 进行订阅
77
+ 5. 通过 dispatch 派发 state 的操作指令
78
79
+- 使用 RTK 简化 redux 操作(RTK 分支)
0 commit comments