Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Android project to use AndroidX support library #22

Closed
wants to merge 1 commit into from

Conversation

aarongrider
Copy link

Use AndroidX in place of legacy Android support libraries. This is required for any Android projects that use AndroidX for support libraries.

See: https://developer.android.com/jetpack/androidx/migrate

Specifically react-native-gesture-handler currently has a 4 PRs to migrate to AndroidX being blocked by this down stream dependency for our tests that require this dependency.

@ferrannp
Copy link
Contributor

Thank you very much! I'll take a look today or tomorrow.

@ferrannp
Copy link
Contributor

@aarongrider I tried this in a new generated project react-native init with 0.59.5. It does not work (or require some changes in the main project) because the generated project still does not use Android X. I am guessing we need to wait till 0.60.x ?

@ferrannp ferrannp added the blocked Cannot happen right now label Apr 30, 2019
@aarongrider
Copy link
Author

I'm wondering if we should wait to merge this until RN 60 is released with AndroidX support. As far as I understand, AndroidX projects are incompatible with legacy support projects when compiled from source. This library shouldn't be a huge issue for consumers since you distribute compiled aar's, but it's something we should keep in mind.

@krizzu
Copy link
Contributor

krizzu commented May 10, 2019

I'd now use it now, as RN 0.59 is still on support libs plus most of the libs did not move to androidx just yet

@grean
Copy link

grean commented Jun 18, 2019

You should provide a version now even if react-native 0.60 is not yet released...
I could use it now because my project depend on it and it's not working anymore since yesterday -> facebook/react-native#25294
Now other libraries like react-native-webview or react-native-camera have already do the job.
You can merge this PR now and provide a new version, if others don't want androidx they keep previous versions.

@noomorph
Copy link

noomorph commented Jul 4, 2019

0.60 is out. Source: Announcing React Native 0.60

@isaax2
Copy link

isaax2 commented Jul 4, 2019

@@ -5,7 +5,7 @@ buildscript {
minSdkVersion = 16
compileSdkVersion = 28
targetSdkVersion = 27
supportLibVersion = "28.0.0"
supportLibVersion = "1.0.2"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this property name is misleading. Maybe it should be like appcompatVersion ?

@ferrannp
Copy link
Contributor

We want to wait on this till 2.0 is released (so 2.0 is also compatible before RN 0.60.x). Then we can add these changes for 3.0. For now, if you want to use this library in RN 0.60.x just follow the jetifier instructions.

@ferrannp ferrannp removed the on hold label Sep 1, 2019
@isokolovskii
Copy link

@aarongrider @ferrannp @troZee any updates on this one? 2.0.0 is out and RN is already 0.61

Jetifier is doing it's job, however I think it's already time to migrate

@devvit devvit mentioned this pull request Oct 9, 2019
1 task
@ghost
Copy link

ghost commented Nov 4, 2019

@ferrannp can you please merge this and push a new release ?

@ferrannp
Copy link
Contributor

@aarongrider hey I am closing this in favour of #103. Sorry for that! But we also need the example working if we update to Android X so we want to speed things up. We'll make a new release when that is merged.

@bhandarijiwan till then just use jetifier or run react-native run-android which does it for you.

@ferrannp ferrannp closed this Nov 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants