Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DefaultGzipConfig is the default Gzip middleware config. DefaultGzipConfig = GzipConfig{ Skipper: skipper.DefaultSkipper, Level: -1, } )
Functions ¶
func GzipWithConfig ¶
func GzipWithConfig(config GzipConfig) macross.Handler
GzipWithConfig return Gzip middleware with config. See: `Gzip()`.
Types ¶
type GzipConfig ¶
type GzipConfig struct { // Skipper defines a function to skip middleware. Skipper skipper.Skipper // Gzip compression level. // Optional. Default value -1. Level int `json:"level"` }
GzipConfig defines the config for Gzip middleware.
Click to show internal directories.
Click to hide internal directories.