React-native-firebase: Find out how get know version of firebase sdk you are using

Created on 25 Nov 2019  路  1Comment  路  Source: invertase/react-native-firebase

Hey guys, sorry I didn't know which type submit this question.
At the end I preferred documentation feedback.

I've been trying to understand witch versions of core libraries I'm using
..maybe it's a stupid question..
My react-native project using these dependencies:

"@react-native-firebase/analytics": "^6.0.3",
"@react-native-firebase/app": "^6.0.3",
"@react-native-firebase/crashlytics": "^6.0.3",

Which are the version of native libraries?
Have they same version? I mean:
Firebase Core 6.0.3
Firebase Crashlytics 6.0.3
Firebase Analytics 6.0.3

This is dependecies in android/app/build.gradle
`
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation "com.facebook.react:react-native:+" // From node_modules
implementation "com.google.android.gms:play-services-base:16.0.1"
implementation('com.crashlytics.sdk.android:crashlytics:2.9.5@aar') {
transitive = true
}

if (enableHermes) {
       def hermesPath = "../../node_modules/hermes-engine/android/";
      debugImplementation files(hermesPath + "hermes-debug.aar")
      releaseImplementation files(hermesPath + "hermes-release.aar")
} else {
     implementation jscFlavor
}

`

Thank for the help

Question

Most helpful comment

For iOS you want `cat ios/Podfile.lock |grep Firebase/' to determine underlying SDK versions.

For Android you can do cd android && ./gradlew :app:dependencies |sort|uniq

but I prefer not only to know but to control things exactly. You can implement that exact control like so: https://github.com/mikehardy/rnfbdemo/blob/master/make-demo-v6.sh#L28 but it will come with the burden of tracking the upstream releases yourself and checking if upgrades are compatible with the react-native-firebase version. For that reason they bundle a known version in their .podspec and .gradle files

>All comments

For iOS you want `cat ios/Podfile.lock |grep Firebase/' to determine underlying SDK versions.

For Android you can do cd android && ./gradlew :app:dependencies |sort|uniq

but I prefer not only to know but to control things exactly. You can implement that exact control like so: https://github.com/mikehardy/rnfbdemo/blob/master/make-demo-v6.sh#L28 but it will come with the burden of tracking the upstream releases yourself and checking if upgrades are compatible with the react-native-firebase version. For that reason they bundle a known version in their .podspec and .gradle files

Was this page helpful?
0 / 5 - 0 ratings