Documentation ¶
Index ¶
Constants ¶
View Source
const ( AccessControlAllowOrigin = "Access-Control-Allow-Origin" AccessControlAllowMethods = "Access-Control-Allow-Methods" AccessControlAllowHeaders = "Access-Control-Allow-Headers" AccessControlAllowCredentials = "Access-Control-Allow-Credentials" )
Variables ¶
This section is empty.
Functions ¶
func CORS ¶
func CORS(config ...CORSConfig) gsk.Middleware
func RequestLogger ¶ added in v0.5.3
func RequestLogger(next gsk.HandlerFunc) gsk.HandlerFunc
func SecurityHeaders ¶
func SecurityHeaders(next gsk.HandlerFunc) gsk.HandlerFunc
Types ¶
type CORSConfig ¶ added in v0.5.3
type RateLimiter ¶
type RateLimiter struct { Middleware gsk.Middleware // contains filtered or unexported fields }
func NewRateLimiter ¶
func NewRateLimiter(rlConfig ...RateLimiterConfig) *RateLimiter
type RateLimiterConfig ¶ added in v0.5.3
Click to show internal directories.
Click to hide internal directories.