layout: title: “setTimeout” date: 2017-10-10 09:12 categories: —
setTimes() function
Is commonly used if you wish to have your function called once the specified delay.
The seInterval() function is commonly used of set a delay for functions that are executed again and again such a animations.
The setTimeout() method calls a function or evaluates an expression after a specied number of milliseconds.
The function is only executed once. If you need to repeat execution, use the setLnterval() method.
Use the clearTimeout() method to prevent the function from running.