//go:build embedfrontend

package web

import (
	"embed"
	"io/fs"
)

// The Docker build copies the Vite output (apps/oncall-web -> build/) into
// ./web/build and compiles with -tags embedfrontend, baking the SPA into the
// binary so a single image/Pod serves both the API and the frontend.
//
//go:embed all:build
var embedded embed.FS

func init() {
	sub, err := fs.Sub(embedded, "build")
	if err != nil {
		panic(err)
	}
	frontendFS = sub
}
