Flashing title notification in Javascript ES6.

1 year ago23k times

To flash title notification in Javascript ES6. we will use setInterval function.


let showalert = false;
const interval = setInterval(()=>{
  document.title = showalert ? 'Chat Application' : '(1) New Message';
},1000);

Add Answer

Add a codeAdd Code
Remove adsremove

Latest codes

view all

Latest Snippets

view all