diff --git a/server.go b/server.go index 74fa2fa..3157a96 100644 --- a/server.go +++ b/server.go @@ -8,6 +8,9 @@ import ( "time" ) +//go:embed static +var staticDir embed.FS + //go:embed index.html var indexTemplate string @@ -29,6 +32,7 @@ var tplFunctions = template.FuncMap{"formatTime": formatTime} func serveHttp() { http.HandleFunc("/", handleIndex) + http.Handle("/static/", http.FileServer(http.FS(staticDir))) log.Println("Serving on port 4444")