• Creating a self-correcting alternative to JavaScript’s setInterval

    Recently, I’ve been toying with JavaScript’s setInterval method which, if you’re unfamiliar, allows you to execute code repeatedly at a specified time interval. For example, one might create an interval which executes every second by using the following code snippet: setInterval( function() { console.log( ‘I execute every second!’ ); }, 1000 ); Both setInterval and […]