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

Using SDK Version variables from root project #714

Merged
merged 3 commits into from
Jul 20, 2018

Conversation

rayronvictor
Copy link
Contributor

Instead of assuming the compileSdkVersion, targetSdkVersion, etc, read it from the root project.
Default compileSdkVersion and targetSdkVersion to the latest versions.

Android Target API Level 26 will be required in August 2018.
https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html
And the React Native team is already working on this:
facebook/react-native#17741
facebook/react-native#18095

Instead of assuming the `compileSdkVersion`, `targetSdkVersion`, etc, read it from the root project.
Default `compileSdkVersion` and `targetSdkVersion` to the latest versions.

Android Target API Level 26 will be required in August 2018.
https://android-developers.googleblog.com/2017/12/improving-app-security-and-performance.html
And the React Native team is already working on this:
facebook/react-native#17741
facebook/react-native#18095
@oblador
Copy link
Owner

oblador commented May 30, 2018

Thanks! Would you mind documenting this too?

@@ -10,13 +10,21 @@ buildscript {

apply plugin: 'com.android.library'

def _ext = rootProject.ext
Copy link
Owner

Choose a reason for hiding this comment

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

Why the _ prefix for all variables, can you rename the variables to something more sensible?

@@ -10,13 +10,21 @@ buildscript {

apply plugin: 'com.android.library'

def _ext = rootProject.ext

def _reactNativeVersion = _ext.has('reactNative') ? _ext.reactNative : '+'
Copy link
Owner

Choose a reason for hiding this comment

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

Wouldn't it make sense to have the setting be named reactNativeVersion for consistency?

@alexismoreau
Copy link

alexismoreau commented Jun 19, 2018

It works well, maybe you should use implementation instead of compile to avoid the deprecated warning.
Thanks !

Copy link
Owner

@oblador oblador left a comment

Choose a reason for hiding this comment

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

Renamed variables for consistency, otherwise LGTM!

@oblador oblador merged commit cfb58ca into oblador:master Jul 20, 2018
@jeaye
Copy link

jeaye commented Jul 20, 2018

I came here to also fork and make a PR for this. Thanks for beating me to it! Can we get a new release, please?

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.

4 participants