aMarCruz / react-native-text-size

Measure text accurately before laying it out and get font information from your App.
BSD 2-Clause "Simplified" License
405 stars 95 forks source link

Load Android Gradle Plugin conditionally #22

Open SaeedZhiany opened 4 years ago

SaeedZhiany commented 4 years ago

This wraps the Android Gradle plugin dependency in the buildscripts section of android/build.gradle in a conditional:

if (project == rootProject) {
    // ... (dependency here)
}

The Android Gradle plugin is only required when opening the project stand-alone, not when it is included as a dependency. By doing this, the project opens correctly in Android Studio, and it can also be consumed as a native module dependency from an application project without affecting the app project (avoiding unnecessary downloads/conflicts/etc).

for more info, you can refer to this thread and especially this comment.

SaeedZhiany commented 3 years ago

@aMarCruz

can you please review and merge this?

also, publish a new version on npm if it's possible.

Thanks

vasylnahuliak commented 1 year ago

Feel free to use this fork https://github.com/vasylnahuliak/react-native-text-size

SaeedZhiany commented 1 year ago

Feel free to use this fork https://github.com/vasylnahuliak/react-native-text-size

@vasylnahuliak

Are you plan to actively maintain your fork? if yes, @aMarCruz can transfer the ownership of his repository to you (according to the Readme of the repository, in case you missed the section before creating a new fork).

image
vasylnahuliak commented 1 year ago

I do not have any plan for active maintenance. This fork pointed to fixing compatibility with React Native 0.72.