Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could do this but there's a small inconsistency in that the WWW version re-exports a GK which does not have a DEV check. I'd rather have them all consistent. Currently I think we always check for
__DEV__
in the source anyway before any behavioral changes. So I'd propose either:true
__DEV__
and change WWW feature flag to be__DEV__ && FeatureFlagsWWW.enableStrictEffects
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it makes more sense to compare to other flags within this feature flags file rather than www. So this would be more like
debugRenderPhaseSideEffectsForStrictMode
right above it.Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, but this is to enable static dead code elimination in production builds even if there's a dynamic flag (like in www). I think the feature flags still generally use
__DEV__
or__PROFILING__
to be explicit. :)Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm thinking of a situation where we add some behavior difference in the source without checking
__DEV__
before it (by mistake). Then, if WWW and OSS flags diverge in this way, you'd see the different behavior in production on WWW than in production in OSS. That seems like a risky divergence.Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then let's change the
OSSwww export too.There's good reason to keep the extra static
__DEV__
wrapper (mentioned above) and I think there's also value in keeping the feature flags more scoped/explicit about DEV-only features.