Skip to content

Commit db6c98e

Browse files
mdvaccafacebook-github-bot
authored andcommittedJan 30, 2024·
Deprecate com/facebook/react/config/ReactFeatureFlags (#42718)
Summary: Pull Request resolved: #42718 Deprecate com/facebook/react/config/ReactFeatureFlags, to be replaced by com.facebook.react.internal.featureflags.ReactNativeFeatureFlags changelog: [internal] internal Reviewed By: NickGerleman Differential Revision: D53199655 fbshipit-source-id: 32bdc526e377ff70e2df3c97a259066a25180231
1 parent c7479b0 commit db6c98e

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed
 

‎packages/react-native/ReactAndroid/src/main/java/com/facebook/react/config/ReactFeatureFlags.java

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
*
1818
* <p>These values are safe defaults and should not require manual changes.
1919
*/
20+
@Deprecated(since = "Use com.facebook.react.internal.featureflags.ReactNativeFeatureFlags instead.")
2021
@DoNotStripAny
2122
public class ReactFeatureFlags {
2223
/**

‎packages/react-native/ReactAndroid/src/main/java/com/facebook/react/defaults/DefaultNewArchitectureEntryPoint.kt

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import com.facebook.react.config.ReactFeatureFlags
2525
object DefaultNewArchitectureEntryPoint {
2626
@JvmStatic
2727
@JvmOverloads
28+
@Suppress("DEPRECATION")
2829
fun load(
2930
turboModulesEnabled: Boolean = true,
3031
fabricEnabled: Boolean = true,

‎packages/rn-tester/android/app/src/main/java/com/facebook/react/uiapp/RNTesterApplication.kt

+4
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ class RNTesterApplication : Application(), ReactApplication {
4949
name: String,
5050
reactContext: ReactApplicationContext
5151
): NativeModule? {
52+
@Suppress("DEPRECATION")
5253
if (!ReactFeatureFlags.useTurboModules) {
5354
return null
5455
}
@@ -66,6 +67,7 @@ class RNTesterApplication : Application(), ReactApplication {
6667
// modules.
6768
override fun getReactModuleInfoProvider(): ReactModuleInfoProvider =
6869
ReactModuleInfoProvider {
70+
@Suppress("DEPRECATION")
6971
if (ReactFeatureFlags.useTurboModules) {
7072
mapOf(
7173
SampleTurboModule.NAME to
@@ -77,6 +79,7 @@ class RNTesterApplication : Application(), ReactApplication {
7779
false, // isCxxModule
7880
true // isTurboModule
7981
),
82+
8083
SampleLegacyModule.NAME to
8184
ReactModuleInfo(
8285
SampleLegacyModule.NAME,
@@ -86,6 +89,7 @@ class RNTesterApplication : Application(), ReactApplication {
8689
false, // isCxxModule
8790
false // isTurboModule
8891
))
92+
8993
} else {
9094
emptyMap()
9195
}

0 commit comments

Comments
 (0)
Please sign in to comment.