You've already forked pocketbase
mirror of
https://github.com/pocketbase/pocketbase.git
synced 2025-07-16 18:54:22 +02:00
initial public commit
This commit is contained in:
20
ui/embed.go
Normal file
20
ui/embed.go
Normal file
@ -0,0 +1,20 @@
|
||||
// Package ui handles the PocketBase Admin frontend embedding.
|
||||
package ui
|
||||
|
||||
import (
|
||||
"embed"
|
||||
|
||||
"github.com/labstack/echo/v5"
|
||||
)
|
||||
|
||||
//go:embed all:dist
|
||||
var distDir embed.FS
|
||||
|
||||
//go:embed dist/index.html
|
||||
var indexHTML embed.FS
|
||||
|
||||
// DistDirFS contains the embeded dist directory files (without the "dist" prefix)
|
||||
var DistDirFS = echo.MustSubFS(distDir, "dist")
|
||||
|
||||
// DistIndexHTML contains the embeded dist/index.html file (without the "dist" prefix)
|
||||
var DistIndexHTML = echo.MustSubFS(indexHTML, "dist")
|
Reference in New Issue
Block a user