First, it's an enourmous waste of computing resources.
Second, it doesn't even work, since the 'setinterval' is unusable for audio timing.
Third, what's there to show off? So Javascript got a 'PlayWav' function that you call in not so regular intervals depending on buttonstate. Simple beatbox is simple. Could aswell be 30 lines.