Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Dir embed.FS
Functions ¶
func ComposeTitle ¶
ComposeTitle builds the Control UI <title> string based on optional project and command info. Empty values are omitted from the final string.
Types ¶
type SPAHandler ¶
type SPAHandler struct {
// contains filtered or unexported fields
}
SPAHandler serves an embedded single-page app with sensible fallbacks. - Serves static assets when present - Falls back to index.html for client-routed paths
func NewSPAHandler ¶
func NewSPAHandler(root http.FileSystem) *SPAHandler
NewSPAHandler returns an SPA handler without title overrides.
func NewSPAHandlerWithTitle ¶
func NewSPAHandlerWithTitle(root http.FileSystem, title string) *SPAHandler
NewSPAHandlerWithTitle returns an SPA handler that injects the provided title into index.html responses.
func (*SPAHandler) ServeHTTP ¶
func (h *SPAHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
Click to show internal directories.
Click to hide internal directories.