Skip to content

Commit 975cea2

Browse files
authored
Enable debugRenderPhaseSideEffectsForStrictMode in test renderers (facebook#31761)
This flag controls the strict mode double invoke render/lifecycles/etc behavior in Strict Mode. The only place this flag is off is the test renderers, which it should be on for. If we can land this, we can follow up to remove the flag.
1 parent 49b1a95 commit 975cea2

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

packages/shared/forks/ReactFeatureFlags.test-renderer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
import typeof * as FeatureFlagsType from 'shared/ReactFeatureFlags';
1111
import typeof * as ExportsType from './ReactFeatureFlags.test-renderer';
1212

13-
export const debugRenderPhaseSideEffectsForStrictMode = false;
13+
export const debugRenderPhaseSideEffectsForStrictMode = __DEV__;
1414
export const enableAsyncDebugInfo = false;
1515
export const enableSchedulingProfiler = false;
1616
export const enableProfilerTimer = __PROFILE__;

packages/shared/forks/ReactFeatureFlags.test-renderer.native-fb.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import typeof * as FeatureFlagsType from 'shared/ReactFeatureFlags';
1111
import typeof * as ExportsType from './ReactFeatureFlags.test-renderer';
1212

1313
export const alwaysThrottleRetries = false;
14-
export const debugRenderPhaseSideEffectsForStrictMode = false;
14+
export const debugRenderPhaseSideEffectsForStrictMode = __DEV__;
1515
export const disableClientCache = true;
1616
export const disableCommentsAsDOMContainers = true;
1717
export const disableDefaultPropsExceptForClasses = true;

packages/shared/forks/ReactFeatureFlags.test-renderer.www.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
import typeof * as FeatureFlagsType from 'shared/ReactFeatureFlags';
1111
import typeof * as ExportsType from './ReactFeatureFlags.test-renderer.www';
1212

13-
export const debugRenderPhaseSideEffectsForStrictMode = false;
13+
export const debugRenderPhaseSideEffectsForStrictMode = __DEV__;
1414
export const enableAsyncDebugInfo = false;
1515
export const enableSchedulingProfiler = false;
1616
export const enableProfilerTimer = __PROFILE__;

0 commit comments

Comments
 (0)