摘要:
1. 创建Redux store app/store.js import { configureStore } from '@reduxjs/toolkit' export default configureStore({ reducer: {} }) 2. 将store提供给React index 阅读全文
posted @ 2023-02-24 20:51
箫笛
阅读(94)
评论(0)
推荐(0)
摘要:
1. store enhancer Store Enhancer基本结构 Store Enhancer是一个函数,这个函数可以接受一个createStore模样的函数为参数,返回一个新的createStore函数。它的主要目的是改变和加强store的接口方法。 const doNothingEnha 阅读全文
posted @ 2023-02-24 20:34
箫笛
阅读(207)
评论(0)
推荐(0)
摘要:
1. 什么是Redux Redux是一个通过叫做action的事件,管理和更新应用程序状态的js库或者说是一种模式。使用Redux 可以使我们更容易地理解应用程序中的状态或者说数据何时,何地,为什么被更新,以及这种更新所 带来的行为。 2. 使用Redux的场景 应用程序中具有大量的数据状态分布在程 阅读全文
posted @ 2023-02-24 20:31
箫笛
阅读(97)
评论(0)
推荐(0)

浙公网安备 33010602011771号