Documentation ¶
Index ¶
- func BasicAuth(fn BasicAuthFunc, options ...*BasicAuthOptions) echo.MiddlewareFunc
- func Favicon() echo.HandlerFunc
- func Gzip(options ...*GzipOptions) echo.MiddlewareFunc
- func Logger(options ...*LoggerOptions) echo.MiddlewareFunc
- func Recover(options ...*RecoverOptions) echo.MiddlewareFunc
- func Static(root string, options ...*StaticOptions) echo.MiddlewareFunc
- type BasicAuthFunc
- type BasicAuthOptions
- type GzipOptions
- type LoggerOptions
- type RecoverOptions
- type StaticOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BasicAuth ¶
func BasicAuth(fn BasicAuthFunc, options ...*BasicAuthOptions) echo.MiddlewareFunc
BasicAuth returns an HTTP basic authentication middleware.
For valid credentials it calls the next handler. For invalid credentials, it sends "401 - Unauthorized" response.
func Favicon ¶
func Favicon() echo.HandlerFunc
Favicon serves the default favicon - GET /favicon.ico.
func Gzip ¶
func Gzip(options ...*GzipOptions) echo.MiddlewareFunc
Gzip returns a middleware which compresses HTTP response using gzip compression scheme.
func Logger ¶
func Logger(options ...*LoggerOptions) echo.MiddlewareFunc
func Recover ¶
func Recover(options ...*RecoverOptions) echo.MiddlewareFunc
Recover returns a middleware which recovers from panics anywhere in the chain and handles the control to the centralized HTTPErrorHandler.
func Static ¶
func Static(root string, options ...*StaticOptions) echo.MiddlewareFunc
Types ¶
type BasicAuthFunc ¶
type BasicAuthOptions ¶
type BasicAuthOptions struct { }
type GzipOptions ¶
type GzipOptions struct {
// contains filtered or unexported fields
}
type LoggerOptions ¶
type LoggerOptions struct { }
type RecoverOptions ¶
type RecoverOptions struct { }
type StaticOptions ¶
Click to show internal directories.
Click to hide internal directories.