ivpusic / react-native-image-crop-picker

iOS/Android image picker with support for camera, video, configurable compression, multiple images and cropping
MIT License
6.09k stars 1.55k forks source link

Duplicate class error #1229

Open whereiscode opened 4 years ago

whereiscode commented 4 years ago

version:0.28.0 rn:0.60.5 android

iOS is ok, but android ...

Error: Attribute activity#com.yalantis.ucrop.UCropActivity@theme value=(@style/Theme.AppCompat.Light.NoActionBar) from [:react-native-image-crop-picker] AndroidManifest.xml:25:13-69 is also present at [com.github.LuckSiege.PictureSelector:picture_library:v2.3.8] AndroidManifest.xml:36:13-58 value=(@style/Base.Theme.NoActionBar). Suggestion: add 'tools:replace="android:theme"' to element at AndroidManifest.xml:23:9-25:72 to override.

gazfcf commented 4 years ago

Try replace

implementation 'com.github.yalantis:ucrop:2.2.5-native'

with

compileOnly 'com.github.yalantis:ucrop:2.2.5-native'

dongdyang commented 3 years ago

compileOnly 'com.github.yalantis:ucrop:2.2.5-native'

does not work for my

BlackStriker99 commented 1 year ago

Add this section in app level build.gradle file in android {} section

 configurations {
        all*.exclude module: 'ucrop' // This removes all other versions of `ucrop` if gets duplicated from all the artifacts.
    }