1 window.addEventListener('load', function(e) {2 3 alert('loaded');4 5 var myObserver = {6 time: 2,7 onidle: function () {8 alert("The user is idle for 10 seconds");9 },10 onactive: function () {11 alert("The user is now active again");12 }13 }14 15 navigator.addIdleObserver(myObserver);16 17 alert('loaded2');18 }, true);19 20 21 22
Enlace
El enlace para compartir es: