README.md in sinatra-assetpack-0.1.1 vs README.md in sinatra-assetpack-0.1.2

- old
+ new

@@ -527,9 +527,35 @@ # >> Thin web server (v1.2.11 codename Bat-Shit Crazy) # >> Maximum connections set to 1024 # >> Listening on 0.0.0.0:4567, CTRL+C to stop ``` +### assets.expires +Sets cache control headers for all assets handled by AssetPack. Defaults to `expires 86400*30, :public`. Passes the arguments to [Sinatras #expires](http://rubydoc.info/gems/sinatra/Sinatra/Helpers#expires-instance_method). + +``` ruby +# Usage: +expires amount, *values +``` + +#### Example +In this example all assets get cached for a year. + +``` ruby +class App < Sinatra::Base + assets { + js_compression :closure + + js :application, [ + '/js/vendor/jquery.*.js', + '/js/vendor/jquery.js' + ] + expires 86400*365, :public + } +end +``` + + API reference: helpers ---------------------- These are helpers you can use in your views.