initial commit

This commit is contained in:
Daniel Hjartland
2024-11-26 18:08:49 +01:00
commit 75be79c6cf
26 changed files with 1885 additions and 0 deletions

10
cache.go Normal file
View File

@@ -0,0 +1,10 @@
package main
import "net/http"
func cacheMiddleware(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
w.Header().Set("Cache-Control", "max-age=3600")
next.ServeHTTP(w, r)
})
}