react-native/ReactCommon
Valentin Shergin c2b0f34533 Introducing on-dirty handler (aka `YGNodeSetDirtiedFunc`)
Summary:
Currently, we can dirty leaf nodes with `measure` function, we also can get `dirty` status for any node, but we cannot handle a moment when this change happen. This diff introduces a new call-back-manner handler for it.
We need this to plug Yoga inside and outside other layout systems without maintaining own dirty propagation infrastructure.
Consider using Yoga for flex-box layout in React Native where we can have deeply nested layout like `<View><Text><View><Text/></View></Text></View>` where all content of all <Text> nodes are laid out using native text/inline (not flex-box!) layout system. In this case, when some change dirties some deeply nested Yoga node, we have to propagate the dirty state down to outer one. Having this handler makes possible to wire up `on-dirty` handler on the root node and `setDirtied` for the leaf node.
Removing custom dirting mechanism from React Native should drastically simplify rendering layer and bring a huge performance win.

Reviewed By: emilsjolander

Differential Revision: D6597856

fbshipit-source-id: 6588cd712f9c1dede4af32f3d326f90103e48ff0
2018-01-10 09:56:41 -08:00
..
cxxreact JSBigString to MAP_PRIVATE not MAP_SHARED 2017-12-20 14:01:33 -08:00
jschelpers move page registration logic in to jsinspector 2017-12-15 09:20:13 -08:00
jsinspector move page registration logic in to jsinspector 2017-12-15 09:20:13 -08:00
microprofiler Replace native cxx_library with fb-specific macros. 2017-12-21 08:58:50 -08:00
privatedata Base class for all object private data passed to JSC 2017-09-18 18:45:27 -07:00
yoga Introducing on-dirty handler (aka `YGNodeSetDirtiedFunc`) 2018-01-10 09:56:41 -08:00
DEFS Fix Travis CI runs 2017-06-02 09:03:18 -07:00