forwardRef是用来解决HOC组件传递ref的问题的,所谓HOC就是Higher Order Component,比如使用redux的时候,我们用connect来给组件绑定需要的state,这其中其实就是给我们的组件在外部包了一层组件,然后通过…props的方式把外部的props传入到实际组
...
组件是react中的一个重要特性。
React.Component源码Component和Pure Component
Component12345678910111213/** * Base class helpers for the updating state of a component.
...