To gitea and beyond, let's go(-yco)
This commit is contained in:
21
internal/handlers/routes.go
Normal file
21
internal/handlers/routes.go
Normal file
@@ -0,0 +1,21 @@
|
||||
package handlers
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"goyco/internal/middleware"
|
||||
|
||||
"github.com/go-chi/chi/v5"
|
||||
)
|
||||
|
||||
type RouteModule interface {
|
||||
MountRoutes(r chi.Router, config RouteModuleConfig)
|
||||
}
|
||||
|
||||
type RouteModuleConfig struct {
|
||||
AuthService middleware.TokenVerifier
|
||||
GeneralRateLimit func(chi.Router) chi.Router
|
||||
AuthRateLimit func(chi.Router) chi.Router
|
||||
CSRFMiddleware func(http.Handler) http.Handler
|
||||
AuthMiddleware func(http.Handler) http.Handler
|
||||
}
|
||||
Reference in New Issue
Block a user