Skip to content

Instantly share code, notes, and snippets.

@naikrovek
Created April 27, 2021 10:56
Show Gist options
  • Save naikrovek/1ba61a60b66f0bb40dbe105b09cd052e to your computer and use it in GitHub Desktop.
Save naikrovek/1ba61a60b66f0bb40dbe105b09cd052e to your computer and use it in GitHub Desktop.
wasm-go-playground change
package main
import (
"embed"
"log"
"net/http"
)
//go:embed cmd/* prebuilt/* index.html jquery-linedtextarea.js playground.js sharing.js style.css wasm_exec.js
var content embed.FS
func main() {
http.Handle("/", http.FileServer(http.FS(content)))
log.Fatal(http.ListenAndServe(":8080", nil))
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment