I'm having some trouble with the android project. When I create a new library and open it for the first time in Android Studio, I see that react-native-0.20.1 is used in the External Libraries (visible in the Project view). (Before I realised this I was having trouble because I wanted to use ReadableArray's toArrayList method, which came later in RN). Clearly this is because this is what's available on MavenCentral (0.20.1 is visible if you search on MavenCentral's site).
I managed to get a later RN version into the external libraries by removing mavenCentral() and adding what is typically found in a RN android project:
mavenLocal()
jcenter()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
}
But then I had problems in the host project I was using the library in, the packager was complaining about multiple RN versions. I previously had my library working fine in the same host project (although with RN 0.20.1, though I didn't know it!).
I'm no android expert unfortunately. How should I go about configuring the library so that I can develop java within Android Studio and be sure that the library works correctly in the host?
First, thank you for a great project!
I'm having some trouble with the android project. When I create a new library and open it for the first time in Android Studio, I see that react-native-0.20.1 is used in the External Libraries (visible in the Project view). (Before I realised this I was having trouble because I wanted to use ReadableArray's toArrayList method, which came later in RN). Clearly this is because this is what's available on MavenCentral (0.20.1 is visible if you search on MavenCentral's site).
I managed to get a later RN version into the external libraries by removing mavenCentral() and adding what is typically found in a RN android project:
But then I had problems in the host project I was using the library in, the packager was complaining about multiple RN versions. I previously had my library working fine in the same host project (although with RN 0.20.1, though I didn't know it!).
I'm no android expert unfortunately. How should I go about configuring the library so that I can develop java within Android Studio and be sure that the library works correctly in the host?
Thanks, hope someone can help!