Cancels a scheduled action initiated by setTimeout()
setTimeout()
note: only js2.0 support
const id = setTimeout(() => {console.log('hello');}, 500);// ...clearTimeout(id); Copy
const id = setTimeout(() => {console.log('hello');}, 500);// ...clearTimeout(id);
Optional
Cancels a scheduled action initiated by
setTimeout()
note: only js2.0 support