ngIdleTimer
AngularJS Module to execute a function when no there's no user interaction after a predefined lapse.
##Installation
-
Download latest release from here
-
Include ngIdleTimer.js in your HTML.
<script src="ngIdleTimer.js"></script>
-
Inject the module in your app.
angular.module('myApp',['ngIdleTimer']);
##Usage
-
Inject ngIdleTimer in your controller
angular.controller('myController',['ngIdleTimer',function(ngIdleTimer){ /* ... */ }]);
-
Set your Idle Timer using
ngIdleTimer.onIdleTimeOut(function, numSeconds);
function is, of course, the function you wan't to be executed when no user interaction is detected after numSeconds seconds