You can check out this fully-commented listing of a pilotwings-style game here: https://turtlespaces.org/weblogo/?pub=182
The backend is written in Golang and compiled to WebAssembly, while the frontend is Javascript.
I used the kaboomjs library which is pretty easy to use.