For cross-framework usage it'd be great if instead of being a render callback, this was distributed as an HTML custom element. Then you could easily use it in any declarative template system, even React/JSX.
I tried to make a web components here: https://lit.dev/playground/#gist=8cf935c3869bf4790653cd6fadf...
But the webgpu-waveform module isn't loading. Looks like you have a hard-coded import of "../../react@18.2.0/index.js", which isn't going to be a portable import even for the React users. For the non-React users, they shouldn't have to install React to get the module loading.
Could you make two entrypoints, one for React, the other for plain JS?