Documentation
¶
Overview ¶
Package middlewares exposes the Gothic runtime as a single chi middleware, driven by the Runtime block declared in gothic.config.go. Applied like any chi middleware (router.Use), it keeps main.go tiny while new built-in route features light up automatically on a framework upgrade — the user never edits main.go.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Middleware ¶
Middleware returns a chi middleware — applied like router.Use(middleware.Logger) — that wires the whole Gothic runtime from a single RuntimeConfig: it initializes the cache backend once, then serves the framework's built-in paths (/public/* static assets and the /optimizedImage/* endpoint), letting every other request fall through to the routes you register on the router. New built-in route features are added here and appear automatically.
Types ¶
This section is empty.