React-native-camera: Unable to resolve dependency after install

Created on 11 Sep 2018  路  3Comments  路  Source: react-native-camera/react-native-camera

After installing react-native-camera via "npm install react-native-camera", and then running react-native-link, my build is logging the following errors in Android Studio.

Unable to resolve dependency for ':react-native-camera@debug/compileClasspath': Could not resolve com.facebook.infer.annotation:infer-annotation:+.

and...

Unable to resolve dependency for ':react-native-camera@release/compileClasspath': Could not resolve com.facebook.infer.annotation:infer-annotation:+.

Running React-Native-Camera v1.2.0

Most helpful comment

In android/app build.gradle:

android {
  ...
   defaultConfig {
     ...
     missingDimensionStrategy 'react-native-camera', 'general' <-- insert this line
   }
}

All 3 comments

try to link only this package, i.e.: react-native link react-native-camera

Closing due to missing feedback.

The steps for installing/linking this project are documented under https://github.com/react-native-community/react-native-camera#mostly-automatic-install-with-react-native

@telkandrew If you think the documentation could be improved feel free to send a pull request or reopen this issue with additional infos on what to improve!

In android/app build.gradle:

android {
  ...
   defaultConfig {
     ...
     missingDimensionStrategy 'react-native-camera', 'general' <-- insert this line
   }
}
Was this page helpful?
0 / 5 - 0 ratings

Related issues

vicapow picture vicapow  路  3Comments

grkemtneri picture grkemtneri  路  3Comments

nonameolsson picture nonameolsson  路  3Comments

ghost picture ghost  路  3Comments

Fernando-Parise picture Fernando-Parise  路  3Comments