middleware

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 6, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CORS

func CORS(next http.Handler) http.Handler

CORS middleware injects CORS headers to each request.

func CORSx added in v0.3.0

func CORSx(allowed []string) func(http.Handler) http.Handler

func Recoverer added in v0.3.0

func Recoverer(next http.Handler) http.Handler

Recoverer writes to logs os standard error.

func RecovererWithLog added in v0.3.0

func RecovererWithLog(logWriter io.Writer) func(http.Handler) http.Handler

RecovererWithLog writes to logs when internal error occurred.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL