Ionic 3 | Adding Bug and Crash Reporting System Crashlytics in Ionic Native 3.X

Firebase Crashlytics service is widely used these days by many developers, it helps in reporting crash, bug, and error reporting in your dashboard. This helps a lot to know the reasons behind application crashes and improving user experiences. Firebase Crashlytics is now only used in Native applications, In this tutorial, we will implement to Cordova plugin in Ionic 3 application providing close enough automation in Crash reporting.

 

Let’s get started…

Create new Ionic 3 application by running the following commands

Install the Cordova and Ionic Native plugins

Note: Read Here How to get Fabric_Api_Key and Fabric_Api_Secret?

Import native plugins in app.module.ts

After imports and adding, providers for added plugins file will look like this

Report Error in home.ts

Fabric.io’s Crashlystics service displays error categorized as Fatal or Non-Fatel, we can also download details of bug faced. Bug status report also has device details and application version.

Whenever a new error is thrown you will get notified via email or setting provided in Fabric.io dashboard settings.

Note: It takes 5-10 mins to show errors in dashboard

For testing purposes, I have added a try catch in home.ts

You can check more methods here for reporting error and implementation in your logic having error handling.

So we have implemented Crashlytics in Ionic 3 application this makes error reporting very handy to track issue on real devices.

Leave a Reply

avatar
  Subscribe  
Notify of