Skip to content

Commit

Permalink
Merge pull request #23 from cosmarc/patch-2
Browse files Browse the repository at this point in the history
Fix manifest merger failed error
  • Loading branch information
andreluisjunqueira authored Mar 28, 2019
2 parents 382ed90 + b03b640 commit 903be50
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,20 @@ project(':react-native-documentscanner-android').projectDir = new File(rootProje
include ':openCVLibrary310'
project(':openCVLibrary310').projectDir = new File(rootProject.projectDir,'../node_modules/react-native-documentscanner-android/android/openCVLibrary310')
```

#### In android/app/src/main/AndroidManifest.xml
Change manifest header to avoid "Manifest merger error". After you add `xmlns:tools="http://schemas.android.com/tools"` should look like this:
```
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.<yourAppName>" xmlns:tools="http://schemas.android.com/tools">
```
Add `tools:replace="android:allowBackup"` in <application tag. It should look like this:
```
<application tools:replace="android:allowBackup" android:name=".MainApplication" android:label="@string/app_name" android:icon="@mipmap/ic_launcher" android:allowBackup="false" android:theme="@style/AppTheme">
```
Add Camera permissions request:
```
<uses-permission android:name="android.permission.CAMERA" />
```
#### Add this to android/app/build.gradle (dependencies section)
```
implementation project(':react-native-documentscanner-android')
Expand Down

0 comments on commit 903be50

Please sign in to comment.