Frustrating problem with my pomodoro clock

I’ve got a decent looking pomodoro clock, but the bloody thing doesn’t work. It counts down well enough, but it stops at 1 second, refusing to go any further. I can’t quite figure out what the problem is.

Here is a link to a gist with the code.

You are not able to create a codepen?

I could have done it on Codepen, but I like to be able to do my projects from scratch. Here’s a link to the project on Github Pages, and here’s a link to the repo with the code.

When I test your code it can’t find the audio file.

The program stops at this error:

Uncaught TypeError: Cannot read property 'get' of undefined
    at timer (main.js:33)

On line:
gong.get(0).play()

When you remove that line, the timer continues but looks pretty werid

Thanks for the feedback. I can’t tell you how much I’ve already banged my head on the audio element. Back at it I guess.

Change the name of your gong class. Currently the name is “#gong”, while you may want it named “gong”. Or tell jQuery to find it via $("##gong"). which may be invalid. :wink: