You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From what I understand, renderSlotFragment recursively removes Fragment elements only when the top-level element is a Fragment, and it also removes Fragment components from its children during that process.
I’d like to ask:
If the top-level element is not a Fragment, but one or more of its children are, is it unnecessary to remove those child Fragments as well?
If so, wouldn’t it be sufficient to remove only the top-level Fragment without needing to recurse through the entire tree?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
From what I understand, renderSlotFragment recursively removes Fragment elements only when the top-level element is a Fragment, and it also removes Fragment components from its children during that process.
I’d like to ask:
If the top-level element is not a Fragment, but one or more of its children are, is it unnecessary to remove those child Fragments as well?
If so, wouldn’t it be sufficient to remove only the top-level Fragment without needing to recurse through the entire tree?
Thank you!
Beta Was this translation helpful? Give feedback.
All reactions