SHARE
TWEET

Untitled

a guest Mar 26th, 2019 69 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.     var curr = localStorage.getItem('curr') ? localStorage.getItem('curr') : 0;
  2.     var infiniteToast = setInterval(function () {
  3.         if (curr < messages.length) {
  4.             show_toast(messages[curr]);
  5.             curr++;
  6.             localStorage.setItem('curr',curr);
  7.         }
  8.         else{
  9.             // Очищать не забывай ебло - грузит память
  10.             clearInterval(infiniteToast)
  11.         }        
  12.     }, 2000);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top