-
Notifications
You must be signed in to change notification settings - Fork 45.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reconcile Call component children with current
#11979
Conversation
I'm also wondering if the second argument of react/packages/react-reconciler/src/ReactFiberBeginWork.js Lines 552 to 559 in 48833f6
same as in reconcileChildrenAtExpirationTime ?react/packages/react-reconciler/src/ReactFiberBeginWork.js Lines 118 to 129 in 48833f6
If so, perhaps it's possible to swap Perhaps @gaearon or @sebmarkbage could comment on that? |
Nice, mind adding a test that would previously throw but now passes? |
Will do! |
Seeing that you just dug into the reconciler code for the first time, how was your experience? What do you wish was more documented, what was most confusing etc. |
Added a test for un- and remounting behaviour. I limited myself to the parts of the reconciler that related to the calls and returns. Once I understood the relevant fields and structure of Fiber, and added some log statements throughout, the process started to fall into place. What was most unclear to me is the status of some of the TODO's I ran into, perhaps linking to an issue which contains more context could be useful, such as: react/packages/react-reconciler/src/ReactFiber.js Lines 360 to 367 in 65aeb70
react/packages/react-reconciler/src/ReactFiberBeginWork.js Lines 543 to 545 in 65aeb70
|
Hmm good finds. I think some (both?) of these might be outdated and no longer apply. |
* Add test for un- and remounting children of Call * Reconcile Call component children with `current`
Solves the issue occurring in #11955. Because the
workInProgress.stateNode
was used instead ofcurrent.stateNode
, some Fibers were being deleted twice, causing an invalid state.The implementation of
updateCallComponent
is now also closer toreconcileChildrenAtExpirationTime
.