17 lines
208 B
Go
17 lines
208 B
Go
//go:build serveStatic
|
|
|
|
package static
|
|
|
|
import (
|
|
"embed"
|
|
"net/http"
|
|
)
|
|
|
|
//go:embed static/*
|
|
var staticFS embed.FS
|
|
|
|
func InitHttpHandlers() {
|
|
fs := http.FileServerFS(staticFS)
|
|
http.Handle("/static/", fs)
|
|
}
|