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
When calling Layout.create(c, component) after the component has been measured, it causes the subsequent attribute (including the click handler) to be lost.
What happens is that we end up with two internal nodes for the same components and it doesn't work out well. The problem relates to returning early when we call LayoutState.collectResults() and InternalNode.isNestedTreeHolder() returns true, which is the case when we already have a cached layout for the component associated with the node.
When calling
Layout.create(c, component)
after the component has been measured, it causes the subsequent attribute (including the click handler) to be lost.What happens is that we end up with two internal nodes for the same components and it doesn't work out well. The problem relates to returning early when we call
LayoutState.collectResults()
andInternalNode.isNestedTreeHolder()
returns true, which is the case when we already have a cached layout for the component associated with the node.Code pointers
https://github.com/facebook/litho/blob/master/litho-core/src/main/java/com/facebook/litho/LayoutState.java#L447
https://github.com/facebook/litho/blob/master/litho-core/src/main/java/com/facebook/litho/InternalNode.java#L369
Point of contact: @marco-cova
The text was updated successfully, but these errors were encountered: