Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace usages of YGConfigSetUseLegacyStretchBehaviour #37093

Closed
wants to merge 3 commits into from

Commits on Apr 27, 2023

  1. Set errata level in RN Paper, Litho, and Native Templates

    Summary:
    This searches fbsource for the following strings corresponding to node or config creation using Yoga Java bindings.
    1. `YogaNodeFactory.create`
    2. `YogaConfigFactory.create`
    
    Apart from benchmarks/tests, thie leaves RN Paper, Litho and Native Templates. These are opted into compatibility with current Yoga behavior, using either `YogaErrata.CLASSIC`, or `YogaErrata.ALL` where `UseLegacyStretchBehaviour` is currently set.
    
    Differential Revision: https://internalfb.com/D45299721
    
    fbshipit-source-id: 1814cb375ab0a51e9b0bbb58bd35aac4ce8e33c6
    NickGerleman authored and facebook-github-bot committed Apr 27, 2023
    Configuration menu
    Copy the full SHA
    5b7acc0 View commit details
    Browse the repository at this point in the history
  2. Deprecate Java YogaConfig.setUseLegacyStretchBehaviour()

    Summary: Now that our own usages are removed, mark this as deprecated to encourage users to move to the errata API. The same will be done to variants of this function on other platforms before releasing, and the functions will be removed after releasing.
    
    Differential Revision: D45300343
    
    fbshipit-source-id: 11980ef895bc2bc8073fa6c10df4ccd11eb71c91
    NickGerleman authored and facebook-github-bot committed Apr 27, 2023
    Configuration menu
    Copy the full SHA
    9d4daa6 View commit details
    Browse the repository at this point in the history
  3. Replace usages of YGConfigSetUseLegacyStretchBehaviour (facebook#37093)

    Summary:
    Pull Request resolved: facebook#37093
    
    This replaces product usages of `YGConfigSetUseLegacyStretchBehaviour` with instead setting `YGErrataAll`, to opt out of future conformance fixes which may impact compatibility.
    
    We need to still audit C/C++ usage for where we should be applying `YGErrataClassic`, port this change to the RN desktop fork, then mark the function as deprecated (taking care to allow deprecated functions in the Yoga bindings to call deprecated C ABI functions without warning).
    
    Changelog: [Internal]
    
    Reviewed By: yungsters
    
    Differential Revision: D45300631
    
    fbshipit-source-id: 97b5f4a70f77a590d77248f2a9d2b8fa6633004e
    NickGerleman authored and facebook-github-bot committed Apr 27, 2023
    Configuration menu
    Copy the full SHA
    5fa19e4 View commit details
    Browse the repository at this point in the history