6
Android Studioを使用して、反応したネイティブAndroidブリッジモジュールを開発しようとしています。Android Studioのエラー:解決に失敗しました:com.facebook.react:react-native:+?
このエラーを解決するにはどうすればよいですか?
Error:Failed to resolve: com.facebook.react:react-native:+
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_debugCompile'.
> Could not find any version that matches com.facebook.react:react-native:+.
Searched in the following locations:
file:/Applications/Android Studio.app/Contents/gradle/m2repository/com/facebook/react/react-native/maven-metadata.xml
file:/Applications/Android Studio.app/Contents/gradle/m2repository/com/facebook/react/react-native/
file:/Users/edward3/Library/Android/sdk/extras/android/m2repository/com/facebook/react/react-native/maven-metadata.xml
file:/Users/edward3/Library/Android/sdk/extras/android/m2repository/com/facebook/react/react-native/
file:/Users/edward3/Library/Android/sdk/extras/google/m2repository/com/facebook/react/react-native/maven-metadata.xml
file:/Users/edward3/Library/Android/sdk/extras/google/m2repository/com/facebook/react/react-native/
Required by:
:android:unspecified
Android Studioを使用して/ MyBridgeModule/android /フォルダを開いた。事前に
マイbuild.gradle
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:1.1.1'
}
}
apply plugin: 'com.android.library'
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
defaultConfig {
minSdkVersion 16
targetSdkVersion 22
versionCode 1
versionName "1.0"
ndk {
abiFilters "armeabi-v7a", "x86"
}
}
lintOptions {
warning 'InvalidPackage'
}
}
dependencies {
compile "com.facebook.react:react-native:+"
}
おかげで、
多くの時間を節約できます...ありがとうございます。 –