Generating a crash report using Firebase Crash Report
Knowing when your application crashes and having a log of when that happens can save your application from having all sort of crashing/bad app availability comments over the Play/App Stores. Firebase, with the awesome Crash Report functionality, allows us to do just that, so let's explore how we can make that happen in Android/iOS.
How to do it...
Let us first look at how this recipe is implemented in Android:
- In order to use this awesome feature, you will need to install some dependencies first, so head directly to your
build.gradle
file and add the following line to the dependencies:
compile 'com.google.firebase:firebase-crash:11.0.4'
- Now, simply save and hit that
sync
button; it will download the library and configure your Android project accordingly.
- Please note that in Android, the crash reports are codeless out of the box, but we can make such a flow more human friendly by adding the following line:
FirebaseCrash.log("[*...