android: add R8 keep rules for barcode-scanner Gson references
R8 release minification failed on a missing com.google.gson.annotations .SerializedName referenced by the OutSystems barcode plugin. Suppress the Gson missing-class warning, keep annotations, and keep the plugin's model classes so serialized fields survive shrinking.
This commit is contained in:
Vendored
+8
@@ -19,6 +19,14 @@
|
||||
-dontwarn okio.**
|
||||
-keep class okhttp3.** { *; }
|
||||
|
||||
# Barcode scanner plugin (@capacitor/barcode-scanner -> OutSystems ionbarcode)
|
||||
# references Gson's @SerializedName, but Gson isn't on the release classpath.
|
||||
# Suppress the missing-class warning, keep the annotation attribute, and keep
|
||||
# the plugin's model classes so R8 doesn't strip/rename serialized fields.
|
||||
-dontwarn com.google.gson.**
|
||||
-keepattributes *Annotation*
|
||||
-keep class com.outsystems.plugins.barcode.** { *; }
|
||||
|
||||
# Uncomment this to preserve the line number information for
|
||||
# debugging stack traces.
|
||||
#-keepattributes SourceFile,LineNumberTable
|
||||
|
||||
Reference in New Issue
Block a user