Commit Graph

2 Commits

Author SHA1 Message Date
Samuel Susla 19cd630f04 Clone node with state in yogaNodeCloneCallbackConnector
Summary: Changelog: [Internal]

Reviewed By: shergin

Differential Revision: D23317682

fbshipit-source-id: c273804efbe48143dcecd7c62c4edced0a746bc6
2020-08-25 14:48:38 -07:00
Samuel Susla 6c1ee871c0 Calling ConcreteShadowNode::setStateData sets mostReventState
Summary:
Changelog: [Internal]

If `ConcreteShadowNode::setStateData` is called and the node is cloned before it is mounted, the cloned node will have old state before `setStateData` was called.

To solve this, simply call `setMostRecentState` on the family inside `ConcreteShadowNode::setStateData`.

Reviewed By: JoshuaGross

Differential Revision: D23283560

fbshipit-source-id: f9822fb69e4234f776d512fc02fe13ea7de64897
2020-08-24 01:43:29 -07:00