Files
tefter/server/webdist/webdist.go

18 lines
396 B
Go
Raw Normal View History

// Package webdist embeds the built frontend bundle. The Makefile copies
// ../frontend/dist into this directory before `go build` (go:embed cannot
// reach outside the module directory).
package webdist
import (
"embed"
"io/fs"
)
//go:embed all:dist
var dist embed.FS
// FS returns the frontend bundle rooted at its dist directory.
func FS() (fs.FS, error) {
return fs.Sub(dist, "dist")
}