MIT License
Project represents simple wrapper of standart GO templates to make it simpler.
import (
temp "github.com/gopk/templates/v2"
)
func main() {
render := temp.NewHTMLFS(fs.Context, "", ".html", isNotDebug())
mux := http.NewServeMux()
mux.HandleFunc("/", render.HTTPHandler(func(w http.ResponseWriter, r *http.Request) *temp.HTTPResponse {
return temp.Response(http.StatusOK, "index", params)
})
}