Documentation
¶
Index ¶
- func AllowCredentials(allowCredentials bool) option
- func AllowHeaders(headers []string) option
- func AllowMethods(methods []string) option
- func AllowOrigin(origin []string) option
- func Default() lightning.Middleware
- func ExposeHeaders(headers []string) option
- func New(options ...option) lightning.Middleware
- func SetMaxAge(seconds int) option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AllowCredentials ¶
func AllowCredentials(allowCredentials bool) option
AllowCredentials is an option function that sets whether credentials are allowed
func AllowHeaders ¶
func AllowHeaders(headers []string) option
AllowHeaders is an option function that sets the allowed headers
func AllowMethods ¶
func AllowMethods(methods []string) option
AllowMethods is an option function that sets the allowed HTTP methods
func AllowOrigin ¶
func AllowOrigin(origin []string) option
AllowOrigin is an option function that sets the allowed origins
func ExposeHeaders ¶
func ExposeHeaders(headers []string) option
ExposeHeaders is an option function that sets the exposed headers
func New ¶
func New(options ...option) lightning.Middleware
New returns a new CORS middleware with the given options
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.