我有一个记忆功能组件。父库组件渲染后,react 调用 update memo 组件来检查我的 func.组件需要再次渲染。比较“current.ref === workInProgress.ref”失败并导致我的功能组件重新呈现。
function updateMemoComponent(current, workInProgress, Component, nextProps, updateExpirationTime, renderExpirationTime) {
if (compare(prevProps, nextProps) && current.ref === workInProgress.ref) {
“current.ref === workInProgress.ref”比较是什么意思?你能建议我了解这个的好医生吗? TIA