Updated 24 November 2017
Firebase remote config helps you to change the appearance and behavior of your app without updating it on Playstore. It actually provides you the facility to override some defaults value which was defined in the app from Firebase console at runtime and using those values you can change the appearance and behavior of your app. You can also control the time for which the values will be cached in the app and after that, they will be fetched again. It helps you to perform A/B testing because you can set the values with conditions like countries and many more. Remote Config includes a client library that handles tasks like fetch and caching and provide you the easy control over the time for caching and all.
1 |
compile 'com.google.firebase:firebase-config:11.6.0' |
1 |
mFirebaseRemoteConfig = FirebaseRemoteConfig.getInstance(); |
1 |
mFirebaseRemoteConfig.setDefaults(R.xml.remote_config_defaults); |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
<?xml version="1.0" encoding="utf-8"?> <!-- START xml_defaults --> <defaultsMap> <entry> <key>loading_phrase</key> <value>Fetching config…</value> </entry> <entry> <key>welcome_message_caps</key> <value>false</value> </entry> <entry> <key>welcome_message</key> <value>Welcome to my awesome app!</value> </entry> </defaultsMap> <!-- END xml_defaults --> |
1 2 |
mFirebaseRemoteConfig.getString("loading_phrase") mFirebaseRemoteConfig.getBoolean("welcome_message_caps") |
That’s all, This is a free facility provided by Google so make the best use of it and make your app with dynamic behavior. For more details, you can always refer to the documentation provided by google.
Thank you very much. This is Vedesh Kumar signing off.
If you have more details or questions, you can reply to the received confirmation email.
Back to Home
Be the first to comment.