You can use go’s builtin build features and embed the results into a http.FS.
go generate npm build
go build
And declaring the resulting frontend build as an embed.FS using //go:embed dist/
var frontend *embed.FS
And use that in a http.FShttps://blog.logrocket.com/using-go-generate-reduce-boilerpl...