addEventListener in Javascript triggers the click event automatically

That’s because startCountDown() calls the function startCountDown. Remove the parentheses, and it’ll work.

Leave a Comment