摘要: 在 Container.childContextTypes 中进行接口的声明,通过 getChildContext 返回更新后的state,在 Child.contextTypes 中声明要获取的接口,这样在子组件内部就能通过 this.context 获取到。通过 Context 这样一个中间对象 阅读全文
posted @ 2018-05-31 13:28 点点圈圈一个夏天 阅读(103) 评论(0) 推荐(0) 编辑