I have two WebGPU versions - one that uses fragment shaders and one that uses compute shaders. Although the compute version is supposed to be faster, the fragment version currently runs faster on my iPhone.
Here is a link to my discussion that has links to all 3 versions.
And here is a webpage that describes how to implement the modules in your program.