摘要: response = request() request(callback(response)); request(delegate(response)); response = await request(); monad[request()].then(response); obseverabl 阅读全文
posted @ 2019-07-12 18:35 zzfx 阅读(212) 评论(0) 推荐(0)
摘要: 我们都知道高阶函数是什么, 高阶组件其实是差不多的用法,只不过传入的参数变成了react组件,并返回一个新的组件. A higher-order component is a function that takes a component and returns a new component. 形 阅读全文
posted @ 2019-07-12 16:28 zzfx 阅读(295) 评论(0) 推荐(0)
摘要: redux = monand + pipeline + highorder componet + decouple + middleware redex = store based + event handler redux = function managers redux = 状态处理的流程管理 阅读全文
posted @ 2019-07-12 15:09 zzfx 阅读(239) 评论(0) 推荐(0)
摘要: 要素: 1、高阶函数:reduce; 2、处理函数:reducer; 3、数据:可以是具体数据、签名相同的普通函数、签名相同的高阶函数; reduce(reducer, datas(data or funciton), initResult(optional)) 一、平凡数据处理 1 In [5]: 阅读全文
posted @ 2019-07-12 15:07 zzfx 阅读(274) 评论(0) 推荐(0)
摘要: let newStore = applyMiddleware(mid1, mid2, mid3, ...)(createStore)(reducer, null); 给({ getState, dispatch }) => next => action签名的函数组分步赋值并进行串联的过程; 整体上是 阅读全文
posted @ 2019-07-12 12:37 zzfx 阅读(197) 评论(0) 推荐(0)
摘要: What’s is the benefit / drawback of these two alternatives? Using object spread options = {...optionsDefault, ...options}; Or using Object.assign opti 阅读全文
posted @ 2019-07-12 12:02 zzfx 阅读(284) 评论(0) 推荐(0)