title: gzip assets in Sinatra app
body: <p>I have been reading that zipping your assets using gzip will increase the performance of a site. There seems to be many ways to do this in a Sinatra application, so i was looking to confirm the most effective and easiest way to understand.</p>
  
  <p>I have come across </p>
  
  <pre><code>use Rack::Deflater
  </code></pre>
  
  <p>Which should be placed in my config.ru file before running the app, so in my case </p>
  
  <pre><code>require './david'
  use Rack::Deflater
  run Sinatra::Application
  </code></pre>
  
  <p>is that it? is it this simple, Just to add I know this will zip all my static assets, including my images, but these are served from a CDN so would that make a difference?</p>
  
  <p>Ant help appreciated with this one</p>
  
  <p>Thanks</p>