Sololearn: Learn to Code
New course! Every coder should learn Generative AI!
Try a free lesson
+ 8
Nasratullah Talash setInterval fires again and again in intervals, while setTimeout only fires once. setTimeout(): It is a function that execute a JavaScript statement AFTER x interval. setTimeout(function() { something(); }, 1000); // Execute something() 1 second later. source: https://stackoverflow.com/questions/2696692/setinterval-vs-settimeout I hope I was helpful
22nd May 2019, 1:54 PM
Alessio Benvenuti
Alessio Benvenuti - avatar