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
Every time we move a node we may be doing exactly this. And this means that such a node ends up in being someTree's and someElement's child.
Fortunately, in the view we bubble events using the parent chain so the events bubble to the new tree. But it may lead to issues anyway, especially in the tests.
E.g. I've just seen a code which did this:
const el = somElement.getChild( 0 );
new ViewElement( 'foo', null, [ el ] );
Which has exactly the same meaning as the move operation above. I don't want to be the first person who will spend a day debugging an issue caused by a node being in two places so I think we should prevent it.
The text was updated successfully, but these errors were encountered:
I think it won't be as many as you think because those bugs often show up pretty fast. But I agree for 100% that this should be changed. I myself did this kind of error twice already.
I wonder how many times we do this:
Every time we move a node we may be doing exactly this. And this means that such a node ends up in being someTree's and someElement's child.
Fortunately, in the view we bubble events using the
parent
chain so the events bubble to the new tree. But it may lead to issues anyway, especially in the tests.E.g. I've just seen a code which did this:
Which has exactly the same meaning as the move operation above. I don't want to be the first person who will spend a day debugging an issue caused by a node being in two places so I think we should prevent it.
The text was updated successfully, but these errors were encountered: