/gzip

Martini handler for adding gzip compress to requests

Primary LanguageGoMIT LicenseMIT

gzip wercker status

Gzip middleware for Martini.

API Reference

Usage

import (
  "github.com/codegangsta/martini"
  "github.com/martini-contrib/gzip"
)

func main() {
  m := martini.Classic()
  // gzip every request
  m.Use(gzip.All())
  m.Run()
}

Make sure to include the Gzip middleware above other middleware that alter the response body (like the render middleware).

Authors