A thin wrapper for dyff that builds a WebAssembly binary and provides a static webpage to run the diff with basic syntax highlighting, available here.
GOOS=js GOARCH=wasm go build -trimpath -ldflags="-s -w" -o web/app.wasm ./cmd/wasm
cp "$(go env GOROOT)/lib/wasm/wasm_exec.js" web/wasm_exec.js
The /web directory will contain all the necessary files to deploy to any static site hosting.
The binary can be further optimized with wasm-opt, if desired:
wasm-opt -Oz web/app.wasm -o web/app.wasm --all-features