server proxy, router opts and optional CORS.

This commit is contained in:
Miroslav Šedivý
2023-11-19 14:35:19 +01:00
parent cd9d31a627
commit 501280f8aa
4 changed files with 95 additions and 33 deletions

View File

@ -17,9 +17,7 @@ type Router interface {
Patch(pattern string, fn RouterHandler)
Delete(pattern string, fn RouterHandler)
With(fn MiddlewareHandler) Router
WithBypass(fn func(next http.Handler) http.Handler) Router
Use(fn MiddlewareHandler)
UseBypass(fn func(next http.Handler) http.Handler)
ServeHTTP(w http.ResponseWriter, req *http.Request)
}