Ale*_*Fux 7 gradle android-studio react-native react-native-android
我有反应原生项目,使用react-native@0.36.0.我正在尝试将版本升级到0.40.0.在build.gradle中有以下行:
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.0'
}
}
apply plugin: 'com.android.library'
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
defaultConfig {
minSdkVersion 16
targetSdkVersion 23
versionCode 1
versionName "1.0"
}
lintOptions {
abortOnError false
}
}
repositories {
mavenLocal()
jcenter()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$projectDir/../../../node_modules/react-native/android"
}
}
dependencies {
compile 'com.facebook.react:react-native:+'
compile 'org.slf4j:slf4j-api:1.7.22'
}
Run Code Online (Sandbox Code Playgroud)
当更新了反应原生的npm版本时,所有"import com.facebook.react"变为红色.我错过了什么?
谢谢.
更新:我看到在/ build/intermediates/explosion-aar中有版本0.36.0,尽管在app.iml中我有行:
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.facebook.react/react-native/0.40.0/jars" />
Run Code Online (Sandbox Code Playgroud)
和
<orderEntry type="library" exported="" name="react-native-0.40.0" level="project" />
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
541 次 |
| 最近记录: |