My sketchbook for the wasm with golang. Please refer the WebAssembly.
Write it with a command using fish
shell.
env GOOS=js GOARCH=wasm go build -o main.wasm
cp (go env GOROOT)/misc/wasm/wasm_exec.js .
go get -u github.com/shurcooL/goexec
goexec 'http.ListenAndServe(":8080", http.FileServer(http.Dir(".")))'