Skip to content

Commit 1ce9946

Browse files
javachemeta-codesync[bot]
authored andcommitted
Rollout useShadowNodeStateOnClone in featureflag config (#54921)
Summary: Pull Request resolved: #54921 Set the default for `useShadowNodeStateOnClone` in featureflags rather than manually overriding it in `ReactNativeFeatureFlagsOverridesOSSStable.h` This rolls out the `useShadowNodeStateOnClone` feature flag to all internal RN apps following rollout in OSS and experimentation in FB4A (https://fb.workplace.com/groups/362274192795505/posts/810523431303910/) Changelog: [Internal] Reviewed By: cipolleschi, lenaic Differential Revision: D89373358 fbshipit-source-id: 15dbd68cd481864c781851031abdc93584edbfdd
1 parent d25af38 commit 1ce9946

6 files changed

Lines changed: 8 additions & 14 deletions

File tree

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsDefaults.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* This source code is licensed under the MIT license found in the
55
* LICENSE file in the root directory of this source tree.
66
*
7-
* @generated SignedSource<<58cb08dbd188ec64d3738f548567bcde>>
7+
* @generated SignedSource<<bb85527f5c9affa81a1ea33f2873a957>>
88
*/
99

1010
/**
@@ -187,7 +187,7 @@ public open class ReactNativeFeatureFlagsDefaults : ReactNativeFeatureFlagsProvi
187187

188188
override fun useRawPropsJsiValue(): Boolean = true
189189

190-
override fun useShadowNodeStateOnClone(): Boolean = false
190+
override fun useShadowNodeStateOnClone(): Boolean = true
191191

192192
override fun useSharedAnimatedBackend(): Boolean = false
193193

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsOverrides_RNOSS_Stable_Android.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,4 @@ public class ReactNativeFeatureFlagsOverrides_RNOSS_Stable_Android() :
1111
ReactNativeNewArchitectureFeatureFlagsDefaults() {
1212

1313
override fun useFabricInterop(): Boolean = true
14-
15-
override fun useShadowNodeStateOnClone(): Boolean = true
1614
}

packages/react-native/ReactCommon/react/featureflags/ReactNativeFeatureFlagsDefaults.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* This source code is licensed under the MIT license found in the
55
* LICENSE file in the root directory of this source tree.
66
*
7-
* @generated SignedSource<<5586a2963cb339f4d5241c790da60d62>>
7+
* @generated SignedSource<<33cacaaeb6994f78f5a2d9379618e2a0>>
88
*/
99

1010
/**
@@ -356,7 +356,7 @@ class ReactNativeFeatureFlagsDefaults : public ReactNativeFeatureFlagsProvider {
356356
}
357357

358358
bool useShadowNodeStateOnClone() override {
359-
return false;
359+
return true;
360360
}
361361

362362
bool useSharedAnimatedBackend() override {

packages/react-native/ReactCommon/react/featureflags/ReactNativeFeatureFlagsOverridesOSSStable.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,5 @@ class ReactNativeFeatureFlagsOverridesOSSStable : public ReactNativeFeatureFlags
2929
{
3030
return true;
3131
}
32-
bool useShadowNodeStateOnClone() override
33-
{
34-
return true;
35-
}
3632
};
3733
} // namespace facebook::react

packages/react-native/scripts/featureflags/ReactNativeFeatureFlags.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -921,15 +921,15 @@ const definitions: FeatureFlagDefinitions = {
921921
ossReleaseStage: 'none',
922922
},
923923
useShadowNodeStateOnClone: {
924-
defaultValue: false,
924+
defaultValue: true,
925925
metadata: {
926926
dateAdded: '2025-04-16',
927927
description:
928928
'Use the state stored on the source shadow node when cloning it instead of reading in the most recent state on the shadow node family.',
929929
expectedReleaseValue: true,
930930
purpose: 'experimentation',
931931
},
932-
ossReleaseStage: 'none',
932+
ossReleaseStage: 'stable',
933933
},
934934
useSharedAnimatedBackend: {
935935
defaultValue: false,

packages/react-native/src/private/featureflags/ReactNativeFeatureFlags.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* This source code is licensed under the MIT license found in the
55
* LICENSE file in the root directory of this source tree.
66
*
7-
* @generated SignedSource<<b16ca6ca4e47b347e4f5cb8555d3308f>>
7+
* @generated SignedSource<<6b37c02e334fb00f22ce27bb787104cc>>
88
* @flow strict
99
* @noformat
1010
*/
@@ -558,7 +558,7 @@ export const useRawPropsJsiValue: Getter<boolean> = createNativeFlagGetter('useR
558558
/**
559559
* Use the state stored on the source shadow node when cloning it instead of reading in the most recent state on the shadow node family.
560560
*/
561-
export const useShadowNodeStateOnClone: Getter<boolean> = createNativeFlagGetter('useShadowNodeStateOnClone', false);
561+
export const useShadowNodeStateOnClone: Getter<boolean> = createNativeFlagGetter('useShadowNodeStateOnClone', true);
562562
/**
563563
* Use shared animation backend in C++ Animated
564564
*/

0 commit comments

Comments
 (0)