Repeating setTimeout

javascript, settimeout

Solution

Maybe you should use `setInterval()`

Problem

I am trying to repeat `setTimeout` every 10 seconds. I know that `setTimeout` by default only waits and then performs an action one time. How can I repeat the process? ``` setTimeout(function() { setTimeout(function() { console.log("10 seconds"); }, 10000); }, 10000); ```

Original source

Related problems