React forwardRef不显示组件的渲染结果

时间:2020-03-18 18:13:01

标签: reactjs react-hooks ag-grid ag-grid-react

我有一个自定义组件的包装,它使用forwardRef

const MyComponentWrapper = forwardRef((props, ref) => (
  <MyComponent {...props} ref={ref}  />
))

MyComponent渲染时没有错误,但没有进行任何布局。可能是什么问题呢? (在MyComponent中一切正常)

0 个答案:

没有答案