As someone who has been in music production and software engineering, I appreciate this. I've also read the article you mentioned when looking at audio latency issues across the web and hybrid mobile app platforms (react native, flutter, ionic capacitor). I immediately found that the web audio API was pretty very solid with it's AudioContext, but there was some audio recording latency on Chrome for Android (hardware plays a role too) and the hybrid app frameworks all had issues with playing back on time, with the audio libraries for flutter being the most solid. My app needed to be able to play two audio tracks exactly at the same time. Anyway I think what you have done is really neat and wish you much success. I'm wonder how most of the users are using it.
Love the simplicity and immediacy of the interface. Storing the pattern in the URL is also awesome, have you considered compressing the string to shorten to URL? (or is it maximally compressed? I guess we can't know..lol)
Here's a random beat I made in about 2 minutes. https://drummy.io/#&p;,eJwz0TE20jE0MtAx0THUMQBjGETnI0SR5TBVE...
Side note: I found https://recme.io/ in the footer, but on Safari 15.1/macOS 12.0.1 recordings result in an error.
It really all boils down to these 20 lines of code!
https://jsfiddle.net/rLesqw05/
The rest of the function is setting up the chances[] array and randomizing length, bpm and figure
Very cool! This reminds of an experiment[0] I made a while back for an alternative pattern composing interface based on the book 'The Geometry of Musical Rhythm: What Makes a "Good" Rhythm Good?' by Godfried Toussaint.
[0] https://michaelmior.github.io/rhythm-wheel/