I have completed the Drum Machine project and it seems as if I have done all of the tests. Whenever I click on the buttons required it plays the corresponding sound and displays message. However, I still continue to fail test 6 and am not sure why. I decided to use hooks and functional components as that is what I was told to do now that it is the common practice. I am not sure if that is why or if it is because I used a for loop inside the handleKeyPress() function as I could not find a more elegant way.
Your code so far
here is a link to my code https://codepen.io/lace1010/pen/KKgexVq
Thank you for the help in advance!
Your browser information:
User Agent is:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.1.3 Safari/605.1.15.
Challenge: Build a Drum Machine
Link to the challenge: