I'm new to React Native and Firebase and decided to improve my knowledge in this regard, I read some articles on interaction and how to connect one to the other, but I can't figure out how to split my app in firebase into dev and prod, because for deva, I want to use collections and logging auth ticks of what I use in development, and when compiling in prod I already used a real collection.
I thought that it could be arranged according to the type of prefixes:
- [Prod] My App
- [Dev] My App
But I see that firebase does not allow me to create another app with the same "Android package name" and, accordingly, I need different SHA1 signatures according to debug.keystore and my [release].keystore, what should I do with this? Can you point me in the right direction, what to look at, what to read to understand this issue, because for the most part what I found is 80% water and 20% what I know myself, but it still does not answer my questions how to be with such separation and how it should behave.
You do not need 2 Google files, one can also work here.
Example:
Create
Development
andStaging
folders insideAndroid/app/src
and put your JSON file thereAdd envConfigFiles inside
android/app/build.gradle
Add resValue in defaultConfig
resValue "string", "build_config_package", "com.package"
Add
flavorDimensions
,signingConfigs
andproductFlavors
above buildTypesAdd these codes inside
buildTypes
after all of these use the below command to build