abobykin / bingo

Bingo game for the website about productivity
0 stars 0 forks source link

# 7 button reset and stop timer. #7

Open Reasonab1e opened 1 week ago

Reasonab1e commented 1 week ago

how to make the buttons stop or reset the timer?

bandicam 2024-07-06 13-37-45-974

abobykin commented 1 week ago

This would be more clear after completing that task - https://github.com/abobykin/bingo/issues/6#issuecomment-2211719408

In addition to those methods implementation (similar way) here on pause action it's maybe useful to store current state of minutes and seconds into some external variables for setting them into the formula for materialTimer.innerText when function with this main setInterval would be started again, by the way if it's not wrapped into the separate function still - then it's time to do this (for not writing another setInterval again).

Try to do this yourself, don't be shy to ask question if you'll get stuck, No worries, that's OK and not bad, but make some work first (and try to win the whole task on your own) !

@Reasonab1e