Some checks are pending
CI Pipeline / Run Tests (push) Waiting to run
CI Pipeline / Lint Code (push) Waiting to run
CI Pipeline / Security Scan (push) Waiting to run
CI Pipeline / Build Docker Images (push) Blocked by required conditions
CI Pipeline / E2E Tests (push) Blocked by required conditions
19 lines
319 B
Go
19 lines
319 B
Go
package web
|
|
|
|
import (
|
|
"embed"
|
|
"io/fs"
|
|
)
|
|
|
|
//go:embed all:*.html all:static/*
|
|
var webFiles embed.FS
|
|
|
|
// GetFS returns the embedded web filesystem
|
|
func GetFS() fs.FS {
|
|
return webFiles
|
|
}
|
|
|
|
// GetFile reads a file from the embedded filesystem
|
|
func GetFile(path string) ([]byte, error) {
|
|
return webFiles.ReadFile(path)
|
|
} |