I need help in this small project

I need help in this small project
0

#1

Hello Everyone, I need help in this small project which I am doing for practice.
I almost copied this project from a website. But my javascript code is not working. Meanwhile the same code which i commented out in the link below works just fine. Can anyone tell me what’s wrong with my javascript code?
Thanks In Advance!


#2

You wrote:

    const audio = document.querySelector(`audio[data-key="${e.keycode}"]`);
    const key = document.querySelector(`div[data-key="${e.keycode}"]`);

“keycode” is not a valid event property. “keyCode” is a valid event property.