Skip to content

Commit 40ac447

Browse files
cortinicometa-codesync[bot]
authored andcommitted
Move to use proguard-android-optimize.txt inside RNTester (facebook#54143)
Summary: Pull Request resolved: facebook#54143 This will become the default in AGP 9.x so let's update it inside RNTester as well. Changelog: [Internal] [Changed] - Reviewed By: cipolleschi Differential Revision: D84548388 fbshipit-source-id: 755344b93204f074926e47ef2a5c980b60e9121b
1 parent 9ab95dd commit 40ac447

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

packages/react-native/ReactAndroid/proguard-rules.pro

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,3 +68,8 @@
6868
-keepclassmembers class * {
6969
@com.facebook.yoga.annotations.DoNotStrip *;
7070
}
71+
72+
# fresco
73+
-keep public class com.facebook.imageutils.** {
74+
public *;
75+
}

packages/rn-tester/android/app/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ android {
122122
buildTypes {
123123
release {
124124
isMinifyEnabled = enableProguardInReleaseBuilds
125-
proguardFiles(getDefaultProguardFile("proguard-android.txt"))
125+
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"))
126126
signingConfig = signingConfigs.getByName("debug")
127127
}
128128
}

private/helloworld/android/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ android {
107107
// see https://reactnative.dev/docs/signed-apk-android.
108108
signingConfig signingConfigs.debug
109109
minifyEnabled enableProguardInReleaseBuilds
110-
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
110+
proguardFiles getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"
111111
}
112112
}
113113
}

0 commit comments

Comments
 (0)