Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MiddlewareFunc ¶
type MiddlewareFunc func(w http.ResponseWriter, r *http.Request)
MiddlewareFunc shortcut for handler func
func JSONHeaderMiddleware ¶
func JSONHeaderMiddleware(f MiddlewareFunc) MiddlewareFunc
JSONHeaderMiddleware sets response as JSON
func LoggingMiddleware ¶
func LoggingMiddleware(app *app.App, f MiddlewareFunc) MiddlewareFunc
LoggingMiddleware add messages to output for each request
func PanicMiddleware ¶
func PanicMiddleware(app *app.App, f MiddlewareFunc) MiddlewareFunc
PanicMiddleware return 500 http status if some panic happen
func RootMiddleware ¶
func RootMiddleware(f MiddlewareFunc) MiddlewareFunc
RootgMiddleware ignore sub pathes
Click to show internal directories.
Click to hide internal directories.