Skip to content
This repository
Browse code

Merge pull request #509 from oscardelben/document_deflater

Document Rack::Deflater
  • Loading branch information...
commit ad80ab7dcd27dd85047aeabb57bdfd9623680125 2 parents fccf545 + 79d35c4
James Tucker authored February 05, 2013

Showing 1 changed file with 12 additions and 0 deletions. Show diff stats Hide diff stats

  1. 12  lib/rack/deflater.rb
12  lib/rack/deflater.rb
@@ -4,6 +4,18 @@
4 4
 require 'rack/utils'
5 5
 
6 6
 module Rack
  7
+  # This middleware enables compression of http responses.
  8
+  #
  9
+  # Currently supported compression algorithms:
  10
+  #
  11
+  #   * gzip
  12
+  #   * deflate
  13
+  #   * identity (no transformation)
  14
+  #
  15
+  # The middleware automatically detects when compression is supported
  16
+  # and allowed. For example no transformation is made when a cache
  17
+  # directive of 'no-transform' is present, or when the response status
  18
+  # code is one that doesn't allow an entity body.
7 19
   class Deflater
8 20
     def initialize(app)
9 21
       @app = app

0 notes on commit ad80ab7

Please sign in to comment.
Something went wrong with that request. Please try again.