mirror of
https://github.com/ditatompel/xmr-remote-nodes.git
synced 2024-12-23 12:09:47 +00:00
22 lines
292 B
Go
22 lines
292 B
Go
|
package frontend
|
||
|
|
||
|
import (
|
||
|
"embed"
|
||
|
"io/fs"
|
||
|
"log"
|
||
|
"net/http"
|
||
|
)
|
||
|
|
||
|
//go:generate npm i
|
||
|
//go:generate npm run build
|
||
|
//go:embed all:build/*
|
||
|
var f embed.FS
|
||
|
|
||
|
func SvelteKitHandler() http.FileSystem {
|
||
|
build, err := fs.Sub(f, "build")
|
||
|
if err != nil {
|
||
|
log.Fatal(err)
|
||
|
}
|
||
|
return http.FS(build)
|
||
|
}
|