fix(teleport): ensure descendent component would be unmounted correctly#6529
fix(teleport): ensure descendent component would be unmounted correctly#6529yyx990803 merged 3 commits intovuejs:mainfrom
Conversation
| !!child.dynamicChildren | ||
| ) | ||
| } | ||
| // an unmounted teleport should always unmount its children whether it's disabled or not |
There was a problem hiding this comment.
this will be a breaking change.
misunderstood.
There was a problem hiding this comment.
The original comment was added in #2870. And it refered to remove but not unmount.
When it comes to remove, there is indeed no need to remove its children when it's disabled and doRmove is false.
But unmount is not equal to remove. We can unmount a child without remove it, by making doRemove false.
While unmounting a component, we should also unmount its children. If not, its children would never be unmounted, and will cause the bug this pr fixes.
|
@edison1105 do you know if this PR could be merged sometime soon? |
Sry Im not sure. |
Size ReportBundles
Usages
|
|
/ecosystem-ci run |
|
📝 Ran ecosystem CI: Open
|
|
Hello, has this submission been published yet? If not, when is it planned to be released? |
|
@Joshua-Leee It's released in v3.3.6. |
fix #6347
This pr makes 2 change.
doRemove || !isTeleportDisabled(props)is false, would unmount children withdoRemovearg being false, instead of doing nothing.doRemoveis false but!isTeleportDisabled(props)is true, would not executehostRemove(anchor!)any more.