Initial commit

This commit is contained in:
mathias
2026-07-19 08:29:23 +00:00
commit 25ad154eac
23 changed files with 747 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
package web
import (
"context"
"net/http"
)
func NewHandler() http.Handler {
mux := http.NewServeMux()
mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
_ = Index().Render(context.Background(), w)
})
mux.HandleFunc("/api/hello", func(w http.ResponseWriter, r *http.Request) {
_ = Hello("world").Render(context.Background(), w)
})
return mux
}