From c55137da5ac464f265ec77543ea71eaad612910a Mon Sep 17 00:00:00 2001 From: David Vacca <515103+mdvacca@users.noreply.github.com> Date: Tue, 23 Jul 2024 20:06:15 -0700 Subject: [PATCH] Delete CoreFeatures::excludeYogaFromRawProps Summary: I'm deleting CoreFeatures::excludeYogaFromRawProps in favor of ReactNativeFeatureFlags::excludeYogaFromRawProps(); changelog: [internal] internal Reviewed By: rubennorte Differential Revision: D60124448 --- .../ReactAndroid/src/main/jni/react/fabric/Binding.cpp | 2 -- .../renderer/components/view/YogaLayoutableShadowNode.cpp | 2 +- packages/react-native/ReactCommon/react/utils/CoreFeatures.cpp | 1 - packages/react-native/ReactCommon/react/utils/CoreFeatures.h | 3 --- 4 files changed, 1 insertion(+), 7 deletions(-) diff --git a/packages/react-native/ReactAndroid/src/main/jni/react/fabric/Binding.cpp b/packages/react-native/ReactAndroid/src/main/jni/react/fabric/Binding.cpp index 71a7e5368c07b0..451520033ce496 100644 --- a/packages/react-native/ReactAndroid/src/main/jni/react/fabric/Binding.cpp +++ b/packages/react-native/ReactAndroid/src/main/jni/react/fabric/Binding.cpp @@ -394,8 +394,6 @@ void Binding::installFabricUIManager( CoreFeatures::enablePropIteratorSetter = ReactNativeFeatureFlags::enableCppPropsIteratorSetter(); - CoreFeatures::excludeYogaFromRawProps = - ReactNativeFeatureFlags::excludeYogaFromRawProps(); auto toolbox = SchedulerToolbox{}; toolbox.contextContainer = contextContainer; diff --git a/packages/react-native/ReactCommon/react/renderer/components/view/YogaLayoutableShadowNode.cpp b/packages/react-native/ReactCommon/react/renderer/components/view/YogaLayoutableShadowNode.cpp index f2ea6fbbbf4cc8..5f8da4d5de5ea0 100644 --- a/packages/react-native/ReactCommon/react/renderer/components/view/YogaLayoutableShadowNode.cpp +++ b/packages/react-native/ReactCommon/react/renderer/components/view/YogaLayoutableShadowNode.cpp @@ -785,7 +785,7 @@ Rect YogaLayoutableShadowNode::getContentBounds() const { } /*static*/ void YogaLayoutableShadowNode::filterRawProps(RawProps& rawProps) { - if (CoreFeatures::excludeYogaFromRawProps) { + if (ReactNativeFeatureFlags::excludeYogaFromRawProps()) { // TODO: this shouldn't live in RawProps rawProps.filterYogaStylePropsInDynamicConversion(); } diff --git a/packages/react-native/ReactCommon/react/utils/CoreFeatures.cpp b/packages/react-native/ReactCommon/react/utils/CoreFeatures.cpp index d1a236bc5e7897..d26d25a5139ffc 100644 --- a/packages/react-native/ReactCommon/react/utils/CoreFeatures.cpp +++ b/packages/react-native/ReactCommon/react/utils/CoreFeatures.cpp @@ -11,6 +11,5 @@ namespace facebook::react { bool CoreFeatures::enablePropIteratorSetter = false; bool CoreFeatures::enableGranularScrollViewStateUpdatesIOS = false; -bool CoreFeatures::excludeYogaFromRawProps = false; } // namespace facebook::react diff --git a/packages/react-native/ReactCommon/react/utils/CoreFeatures.h b/packages/react-native/ReactCommon/react/utils/CoreFeatures.h index b053003bda3041..01a70e2f516f6d 100644 --- a/packages/react-native/ReactCommon/react/utils/CoreFeatures.h +++ b/packages/react-native/ReactCommon/react/utils/CoreFeatures.h @@ -22,9 +22,6 @@ class CoreFeatures { // When enabled, RCTScrollViewComponentView will trigger ShadowTree state // updates for all changes in scroll position. static bool enableGranularScrollViewStateUpdatesIOS; - - // When enabled, rawProps in Props will not include Yoga specific props. - static bool excludeYogaFromRawProps; }; } // namespace facebook::react