1、通过compile "com.facebook.react:react-native:0+"获取到的是react-native-0.20.1,为什么获取不到你们最新的版本(react-native DirectX)?
react-native only publish on npm, so you can reference newest library in node_modules, like this:
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:1.3.1'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
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"
}
}
}
And please ask question on StackOverflow.
@cpunion
我的配置如下:
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.2'
}
}
allprojects {
repositories {
jcenter()
mavenLocal()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$projectDir/../../node_modules/react-native/android"
}
}
}
I created a project and compile with below steps:
react-native init TestVer
cd TestVer/android
./gradlew assembleDebug
Then run find . -iname "*.jar" | grep react-native
, the output is:
./app/build/intermediates/exploded-aar/com.facebook.react/react-native/0.27.2/jars/classes.jar
./app/build/intermediates/exploded-aar/com.facebook.react/react-native/0.27.2/jars/libs/infer-annotations-1.5.jar
It's the newest react-native libraries.
You can generate a new project, and check what is different.
@cpunion I wonder weather you can speak Chinese or not. If you can, why do you answer the question in English.
@cpunion thanks for helping others any way, good job
@cpunion @MingLanCheng
create a react project:
react-native init AwesomeProject
cd AwesomeProject
react-native run-android
Log The following:
@github-lisong
你设置了自己的包依赖库是吧,不是官方的这库。你的库地址
http://jcenter.bintray.com/com/facebook/react/react-native/
最新的版本就是给你下载的0.20.1,没有更新到官方最新的版本,所以你怎么下也都是这个版。
个人猜测原因在这里
你们两个的配置文件有点区别,他的搜索本身仓库在先,你的网络下载在先。
他的机子安装有官方最新版,而你的老去那个没有更新的地址下载老版。
以下是网上找到的更新本地RN的方法,希望有所帮助:
http://blog.csdn.net/wagnteng/article/details/50549869
建议修改配置文件如他那样,搜索本地仓库在前,更新本地版本。
@MingLanCheng
非常感谢你!
你提供的思路,我都尝试过。
http://blog.csdn.net/wagnteng/article/details/50549869 这文章,我之前已看到过,并且按他的思路去做,然而,我还是没有更新到最新的库。
这种问题跑这来开 issue 合适吗?
If you think you have to create an issue to solve the problem, please try to describe it in English so that the others can help you and will help the others who come into the same problem
I've noticed that you also created another issue, beware that here is not QQ group or bbs,
be helpful please, try to find answer on StackOverflow
@facebook-github-bot stack-overflow
Hey @github-lisong and thanks for posting this! @charpeni tells me this issue looks like a question that would be best asked on StackOverflow. StackOverflow is amazing for Q&A: it has a reputation system, voting, the ability to mark a question as answered. Because of the reputation system it is likely the community will see and answer your question there. This also helps us use the GitHub bug tracker for bugs only. Will close this as this is really a question that should be asked on SO.
@nihgwu
你好,我这这里提问题,碍着你嘛事了?合不合适,你算老几,我都懒得理你,FUCK!
@github-lisong shame on you
@charpeni so the ISSUE_TEMPLATE
is useless for those guys 😂
@nihgwu It sounds like. I didn't understand his message, but I guessed by the last word that was not friendly at all.
@github-lisong shame on you.
@github-lisong shame on you.You should read ISSUE_TEMPLATE
first.
@github-lisong Shame on you.
@github-lisong Shame on you
@github-lisong Shame on you
@github-lisong Shame on you.
@github-lisong Shame on you.
@github-lisong Shame on you.
@github-lisong Shame on you.
@github-lisong Shame on you.
Shame on you.
@github-lisong Shame on you.
@github-lisong shame on you.
@github-lisong Shame on you.
@github-lisong Shame on you .
@nihgwu @Edward-Shaw @Jaggle @andyhuzhill @2yuri @harrot @ClassicOldSong 你们都是些什么东西,我提个问题在这里,我得罪你们什么了,有疑问我在这里提有错?你们这帮喜欢装逼的货,我无语死了,只会欺负国人,也没见你们有什么大的能耐,还不是一天用着老外的东西,有能耐得用在刀刃上,呵呵。
@github-lisong 别张口骂人行吗,二逼。我一个一个问题回答你
1,你提个问题在这里,并没有得罪我们什么,就是觉得丢脸
2,有疑问在这里提本身并没有什么大错,但是谦虚谨慎一点不好吗?别人善意提醒你一下看一下issue template,你看你自己什么态度?
3,我们不喜欢装逼,不欺负国人,别为你自己的傻逼行为开脱行吗?
4,至于最后一句话,我都懒着跟你扯扯,还呵呵?我呵呵你一脸。
卧槽,我怎么在github上玩出了百度贴吧的感觉?
Well.. Someone please lock the conversation.
@on99 agree with you, it shouldn't be spawned, and here is my last response
Shame on u too
@github-lisong shame on you
@cqm1994617 可惜github不能楼内回复,233
Most helpful comment
If you think you have to create an issue to solve the problem, please try to describe it in English so that the others can help you and will help the others who come into the same problem
I've noticed that you also created another issue, beware that here is not QQ group or bbs,
be helpful please, try to find answer on StackOverflow