Closed ardyfeb closed 4 years ago
Fixed in #3711, dupe of #3254
Available in public release - update packages, should work - please search issues prior to posting, thanks!
@mikehardy Upgrading packages not fix issue, #3254 is different problem
I tweaked this file to make this package running https://github.com/invertase/react-native-firebase/blob/master/packages/app/android/src/reactnative/java/io/invertase/firebase/app/ReactNativeFirebaseAppRegistrar.java
public class ReactNativeFirebaseAppRegistrar implements ComponentRegistrar {
@Override
public List<Component<?>> getComponents() {
return Collections.singletonList(
LibraryVersionComponent.create(
"react-native-firebase",
- BuildConfig.VERSION_NAME
+ "7.1.4" // package.json version
)
);
}
}
Oh my - that is a different issue. In v5 I had to put that in manually (as you have done). This should be coming from the package.json and not from the app's version though, so I'm not sure it was actually correct.
Either way, see if turning on 'buildConfig' like here works: https://developer.android.com/studio/releases/gradle-plugin#buildFeatures
@Salakar this is another Android Studio 4.0 issue, appears separate, and I'm not sure it was actually correct prior s it's not the library version it would have been the app version (probably a lot of 1.0's...)
Issue
Describe your issue here
Project Files
Javascript
Click To Expand
#### `package.json`: ```json { "name": "pdh", "version": "0.0.1", "private": true, "scripts": { "android": "react-native run-android", "ios": "react-native run-ios", "start": "react-native start", "test": "jest", "lint": "eslint ." }, "dependencies": { "@react-native-community/masked-view": "^0.1.10", "@react-native-community/netinfo": "^5.9.2", "@react-native-firebase/app": "^7.1.0", "@react-native-firebase/crashlytics": "^7.1.0", "@react-native-firebase/database": "^7.1.0", "@react-navigation/native": "^5.5.0", "deox": "^3.2.1", "immer": "^6.0.9", "react": "16.11.0", "react-native": "0.62.2", "react-native-gesture-handler": "^1.6.1", "react-native-paper": "^3.10.1", "react-native-reanimated": "^1.9.0", "react-native-safe-area-context": "^3.0.0", "react-native-screens": "^2.8.0", "react-native-vector-icons": "^6.6.0", "react-redux": "^7.2.0", "redux": "^4.0.5" }, "devDependencies": { "@babel/core": "^7.10.1", "@babel/runtime": "^7.10.1", "@react-native-community/eslint-config": "^1.1.0", "babel-jest": "^26.0.1", "eslint": "^7.1.0", "jest": "^26.0.1", "metro-react-native-babel-preset": "^0.59.0", "react-test-renderer": "16.11.0" }, "jest": { "preset": "react-native" } } ``` #### `firebase.json` for react-native-firebase v6: ```json # N/A ```
Android
Click To Expand
#### Have you converted to AndroidX? - [ x] my application is an AndroidX application? - [ x] I am using `android/gradle.settings` `jetifier=true` for Android compatibility? - [ ] I am using the NPM package `jetifier` for react-native compatibility?