Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Cors ¶
func Cors(corsOption *CorsOption) webing.RequestHandler
================================================================================ * cors * author: 美丽的地球啊 - mliu * ================================================================================
func CorsMiddleware ¶
func CorsMiddleware(corsOption *CorsOption) webing.RequestHandler
Types ¶
type CorsOption ¶
type CorsOption struct {
Domain string //域名
Headers []string //请求头
Methods []string //请求方法
IsCredentials bool //是否cookie
IsAllDomain bool //是否所有域
IsDisabled bool //是否允许跨域
}
================================================================================ * cors middleware * author: 美丽的地球啊 - mliu * ================================================================================
Click to show internal directories.
Click to hide internal directories.