This example is running in WebGL2 and should work in most browsers. You can check the WebGPU examples here.
clear_color.rs:
//! Shows how to set the solid color that is used to paint the window before the frame gets drawn.
//!
//! Acts as background color, since pixels that are not drawn in a frame remain unchanged.
use ;