Resubmit: Expose Unsnapped Dimensions #1811
Reference in New Issue
Block a user
No description provided.
Delete Branch "export-D74673119"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary:
X-link: https://github.com/facebook/react-native/pull/51298
Resubmit
This was backed out due to being up the stack from another change that was backed out, but should be safe by itself.
Original
We want to know if an artifact created during measurement can fully be reused after final layout, but the final layout is allowed to be slightly larger due to pixel grid rounding (while still allowing reuse). It's hard to tell after the fact, whether it is larger because of this rounding (though the measure is used), or if it may be a pixel larger for valid reasons.
We can expose the unsnapped dimensions of a node to give us this information, and to correlate measurement artifacts.
This is most of the time the same as the layout's measured dimension, though I don't think it's safe to use this, since anything else measuring the node after could clobber this (I think
YGNodeLayoutGetOverflow
may also be prone to this as a bug).Changelog: [Internal]
Reviewed By: joevilches
Differential Revision: D74673119
The latest updates on your projects. Learn more about Vercel for Git ↗︎
This pull request was exported from Phabricator. Differential Revision: D74673119
This pull request has been merged in facebook/yoga@c935fd5e10.
Pull request closed