Firebase-iid no longer included in firebase-bom
See original GitHub issueHi! 👋
Firstly, thanks for your work on this project! 🙂
Today I used patch-package to patch react-native-device-info@10.3.0
for the project I’m working on.
Due to an issue found in the android firebase crashlytics SDK it is recommended to update the firebase-bom version to 31.0.1. However, this new version of the bom now does not include the android firebase-iid sdk which is required by this library according to the build.gradle. I’m not entirely certain, but I believe that build.gradle will need an update so that a specific version of the firebase-iid sdk is used when the firebaseBomVersion variable is provided.
The patch diff below is probably not the fully correct way to resolve this, but perhaps it can give an indication of a best path forward to resolve this new issue.
Versions: react-native-device-info: 10.3.0 firebaseBomVersion: 31.0.1
Here is the diff that solved my problem:
diff --git a/node_modules/react-native-device-info/android/build.gradle b/node_modules/react-native-device-info/android/build.gradle
index de22598..016776b 100644
--- a/node_modules/react-native-device-info/android/build.gradle
+++ b/node_modules/react-native-device-info/android/build.gradle
@@ -55,7 +55,7 @@ dependencies {
def firebaseIidVersion = safeExtGet('firebaseIidVersion', null)
if (firebaseBomVersion) {
implementation platform("com.google.firebase:firebase-bom:${firebaseBomVersion}")
- implementation "com.google.firebase:firebase-iid"
+ implementation "com.google.firebase:firebase-iid:${firebaseIidVersion}"
} else if(firebaseIidVersion){
implementation "com.google.firebase:firebase-iid:${firebaseIidVersion}"
}else{
This issue body was partially generated by patch-package.
Issue Analytics
- State:
- Created a year ago
- Comments:5
Top GitHub Comments
Thank you @mikehardy that was very helpful and exactly what I needed. Good work on this library (and react-native-firebase)
Glad that worked I was only 99% sure on it 😅. Worked for me but you never know…