Documentation ¶ Index ¶ func Compress(c *gin.Context, bs []byte) (compressed []byte, err error) Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func Compress ¶ func Compress(c *gin.Context, bs []byte) (compressed []byte, err error) Compress response data by detecting [Accept-Encoding] then use suitable compressor to compress payload, returns compressed bytes if payload greater than 1024 bytes, or original payload with no compress. Types ¶ This section is empty. Source Files ¶ View all Source files conpress.go Click to show internal directories. Click to hide internal directories.