Identifying app resume event in ionic - android

We can use the $ionicPlatform to listen the resume event of an ionic application. This event fires once the application resumes. Have a look at the following sample code

$ionicPlatform.on("resume", function (event) {
	// will execute when device resume.
});

Don't forget to invoke the $ionicPlatform object.

Example:

var app = angular.module('appResumeApp', []);
app.controller('appResumeCtrl', function($ionicPlatform) {
    $ionicPlatform.on("resume", function (event) {
        alert(“Resume Fired”);
    });
});

Category: