mirror of
https://github.com/taigrr/wasm-experiments
synced 2025-01-18 04:03:21 -08:00
24 lines
331 B
Go
24 lines
331 B
Go
//+build generate
|
|
|
|
package main
|
|
|
|
import (
|
|
"log"
|
|
"net/http"
|
|
|
|
"github.com/shurcooL/vfsgen"
|
|
)
|
|
|
|
func main() {
|
|
var fs http.FileSystem = http.Dir("html/")
|
|
|
|
err := vfsgen.Generate(fs, vfsgen.Options{
|
|
Filename: "bundle/bundle.go",
|
|
PackageName: "bundle",
|
|
VariableName: "Assets",
|
|
})
|
|
if err != nil {
|
|
log.Fatalln(err)
|
|
}
|
|
}
|