script.js
// Notice no settings are changed other than to increment the secondsElapsed var
Notice no settings are changed other than to increment the secondsElapsed var
Notice no settings are changed other than to increment the secondsElapsed var
function startTimer() {
  setTime();
  if (totalSeconds > 0) {
      interval = setInterval(function() {
        secondsElapsed++;
        renderTime();
      }, 1000);
  } else {
  }
}
function startTimer ( ) { setTime ( ) ; if ( totalSeconds > 0 ) { interval = setInterval ( function ( ) { secondsElapsed ++ ; renderTime ( ) ; } , 1000 ) ; } else { } }
Notice no settings are changed other than to increment the secondsElapsed var
Notice no settings are changed other than to increment the secondsElapsed var
// We only want to start the timer if totalSeconds is > 0 /* The "interval" variable here using "setInterval()" begins the recurring increment of the
       secondsElapsed variable which is used to check if the time is up */ // So renderTime() is called here once every second.