Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

settimeout in angular

// var that = this;                             // no need of this line
this.messageSuccess = true;

setTimeout(()=>{                           //<<<---using ()=> syntax
      this.messageSuccess = false;
 }, 3000);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #settimeout #angular
ADD COMMENT
Topic
Name
4+6 =