Portability | portable |
---|---|
Stability | Unstable |
Maintainer | Michael Snoyman <michael@snoyman.com> |
Safe Haskell | None |
Automatic gzip compression of responses.
- gzip :: GzipSettings -> Middleware
- data GzipSettings
- gzipFiles :: GzipSettings -> GzipFiles
- data GzipFiles
- gzipCheckMime :: GzipSettings -> ByteString -> Bool
- def :: Default a => a
- defaultCheckMime :: ByteString -> Bool
Documentation
gzip :: GzipSettings -> MiddlewareSource
Use gzip to compress the body of the response.
Analyzes the "Accept-Encoding" header from the client to determine if gzip is supported.
Possible future enhancements:
- Only compress if the response is above a certain size.
gzipCheckMime :: GzipSettings -> ByteString -> BoolSource