Posts

Showing posts from March, 2022

Firebase Database Offline Capabilities | Android Studio | Kotlin

Image
Firebase Offline Capabilities for Firebase Database What if there is a temporary internet issue with your device? What if you don't want to load your database data again & again? Firebase easily allows you to achieve this task by persisting the data locally, managing presence and handling the latency. The data is available offline even if you restart the app or device. It will behave the same as you're online. Firebase keeps a queue of all write operations that are performed while your application is offline e.g. unstable internet connection. When your app becomes online all the queued write operations are sent to the Firebase Realtime Database Server. >>Check For Java Enabling Firebase Offline Persistence Once you enable the  Disk Persistence then the firebase handles the job automatically. You just need to add the following code snippet in your Application Class. MyApplication.java class MyApplication : Application() { override fun onCreate () { sup

Firebase Database Offline Capabilities | Android Studio | Java

Image
Firebase Offline Capabilities for Firebase Database What if there is a temporary internet issue with your device? What if you don't want to load your database data again & again? Firebase easily allows you to achieve this task by persisting the data locally, managing presence and handling the latency. The data is available offline even if you restart the app or device. It will behave the same as you're online. Firebase keeps a queue of all write operations that are performed while your application is offline e.g. unstable internet connection. When your app becomes online all the queued write operations are sent to the Firebase Realtime Database Server. >>Check For Kotlin Enabling Firebase Offline Persistence Once you enable the  Disk Persistence then the firebase handles the job automatically. You just need to add the following code snippet in your Application Class. MyApplication.java public class MyApplication extends Application { @Override publi