8787 < a href ="http://github.com/documentcloud/jammit/ "> Jammit</ a > is an
8888 industrial strength asset packaging library for < b > Rails</ b > , providing
8989 both the CSS and JavaScript concatenation and compression
90- that you'd expect, as well as < b > YUI Compressor</ b > and < b > Closure Compiler</ b >
90+ that you'd expect, as well as < b > YUI Compressor</ b > , < b > Closure Compiler</ b > , and < b > UglifyJS </ b >
9191 compatibility, ahead-of-time gzipping, built-in JavaScript template
9292 support, and optional < b > Data-URI / MHTML image and font embedding</ b > .
9393 </ p >
9494
9595 < p >
96- < b > Current Version:</ b > < a href ="http://rubygems.org/gems/jammit/ "> 0.6.0 </ a >
96+ < b > Current Version:</ b > < a href ="http://rubygems.org/gems/jammit/ "> 0.6.3 </ a >
9797 </ p >
9898
9999 < p >
109109
110110 < h2 > Table of Contents</ h2 >
111111
112- < p style ="line-height: 30px; ">
112+ < p style ="line-height: 30px; width: 650px; ">
113113 < a href ="#installation "> Installation</ a > |
114114 < a href ="#configuration "> Configuration</ a > |
115115 < a href ="#usage "> Usage</ a > |
116- < a href ="#compressors "> YUI & Closure </ a > |
116+ < a href ="#compressors "> YUI, Closure & UglifyJS </ a > |
117117 < a href ="#precaching "> Precaching Assets</ a > < br />
118118 < a href ="#expires "> Expires Headers</ a > |
119119 < a href ="#embedding "> Embedding Assets</ a > |
@@ -161,8 +161,9 @@ <h2 id="installation">Installation</h2>
161161
162162 < p >
163163 < i > Note: If you don't already have the
164- < a href ="http://github.com/sstephenson/ruby-yui-compressor "> ruby-yui-compressor</ a > or
165- < a href ="http://github.com/documentcloud/closure-compiler "> closure-compiler</ a >
164+ < a href ="http://github.com/sstephenson/ruby-yui-compressor "> ruby-yui-compressor</ a > ,
165+ < a href ="http://github.com/documentcloud/closure-compiler "> closure-compiler</ a > or
166+ < a href ="https://github.com/lautis/uglifier "> uglifier</ a >
166167 gems installed, downloading make take a minute — the jar files together
167168 weigh in at 5 megabytes.</ i >
168169 </ p >
@@ -231,7 +232,7 @@ <h2 id="configuration">Configuration</h2>
231232 < td > < tt > on | off</ tt > </ td >
232233 < td class ="definition ">
233234 Defaults to < b > on</ b > . When < b > off</ b > , JavaScript and CSS packages
234- will be left uncompressed (by YUI or Closure ). Disabling compression is only recommended
235+ will be left uncompressed (by YUI, Closure, or UglifyJS ). Disabling compression is only recommended
235236 if you're packaging assets in development.
236237 </ td >
237238 </ tr >
@@ -254,12 +255,12 @@ <h2 id="configuration">Configuration</h2>
254255 </ tr >
255256 < tr >
256257 < td > < b > javascript_compressor</ b > </ td >
257- < td > < tt > yui | closure</ tt > </ td >
258+ < td > < tt > yui | closure | uglifier </ tt > </ td >
258259 < td class ="definition ">
259- Defaults to < b > yui</ b > . As of < b > 0.2.0 </ b > , the Jammit gem can use either the
260- < a href ="http://developer.yahoo.com/yui/compressor/ "> YUI Compressor</ a >
261- or the
262- < a href ="http ://code.google. com/closure/compiler / "> Google Closure Compiler </ a >
260+ Defaults to < b > yui</ b > . The Jammit gem can use either the
261+ < a href ="http://developer.yahoo.com/yui/compressor/ "> YUI Compressor</ a > , the
262+ < a href =" http://code.google.com/closure/compiler/ " > Google Closure Compiler </ a > , or
263+ < a href ="https ://github. com/mishoo/UglifyJS / "> UglifyJS </ a >
263264 to compress your JavaScript.
264265 </ td >
265266 </ tr >
@@ -321,8 +322,9 @@ <h2 id="configuration">Configuration</h2>
321322 < td class ="definition ">
322323 Pass an options hash directly to the underlying JavaScript compressor
323324 to configure it. See the
324- < a href ="http://github.com/sstephenson/ruby-yui-compressor "> ruby-yui-compressor</ a > or
325- < a href ="http://github.com/documentcloud/closure-compiler "> closure-compiler</ a >
325+ < a href ="http://github.com/sstephenson/ruby-yui-compressor "> ruby-yui-compressor</ a > ,
326+ < a href ="http://github.com/documentcloud/closure-compiler "> closure-compiler</ a > , or
327+ < a href ="https://github.com/lautis/uglifier "> uglifier</ a >
326328 gem documentation for the full list of available options.
327329 </ td >
328330 </ tr >
@@ -384,23 +386,25 @@ <h2 id="usage">Usage</h2>
384386 < pre > require 'jammit'
385387Jammit.package!</ pre >
386388
387- < h2 id ="compressors "> YUI & Closure </ h2 >
389+ < h2 id ="compressors "> YUI, Closure & UglifyJS </ h2 >
388390
389391 < p >
390- Jammit can be configured to use either the
391- < a href ="http://developer.yahoo.com/yui/compressor/ "> YUI Compressor</ a > or the
392- < a href ="http://code.google.com/closure/compiler/ "> Google Closure Compiler</ a >
392+ Jammit can be configured to use the
393+ < a href ="http://developer.yahoo.com/yui/compressor/ "> YUI Compressor</ a > , the
394+ < a href ="http://code.google.com/closure/compiler/ "> Google Closure Compiler</ a > , or
395+ < a href ="https://github.com/mishoo/UglifyJS/ "> UglifyJS</ a >
393396 to compress and optimize your JavaScript. (CSS is always run through the
394- YUI Compressor.) Specify the < b > javascript_compressor</ b > to choose either < b > yui</ b >
395- or < b > closure </ b > backends. If left blank, Jammit defaults to < b > yui</ b > .
397+ YUI Compressor.) Specify the < b > javascript_compressor</ b > to choose either < b > yui</ b > ,
398+ < b > closure </ b > , or < b > uglifier </ b > backends. If left blank, Jammit defaults to < b > yui</ b > .
396399 </ p >
397400
398401 < p >
399402 You can configure the JavaScript compilation by adding < b > compressor_options</ b >
400403 to your < b > assets.yml</ b > . The < b > compressor_options</ b >
401404 will be passed directly to the Gem backend of your chosen compressor. See the
402- < a href ="http://github.com/sstephenson/ruby-yui-compressor "> ruby-yui-compressor</ a > or
403- < a href ="http://github.com/documentcloud/closure-compiler "> closure-compiler</ a >
405+ < a href ="http://github.com/sstephenson/ruby-yui-compressor "> ruby-yui-compressor</ a > ,
406+ < a href ="http://github.com/documentcloud/closure-compiler "> closure-compiler</ a > , or
407+ < a href ="https://github.com/lautis/uglifier "> uglifier</ a >
404408 gem documentation for all the available options. For example, to configure
405409 the Closure Compiler to use its
406410 < a href ="http://code.google.com/closure/compiler/docs/compilation_levels.html "> advanced optimizations</ a > ,
@@ -463,8 +467,6 @@ <h2 id="precaching">Precaching Assets</h2>
463467 < a href ="http://rubyhitsquad.com/Vlad_the_Deployer.html "> Vlad</ a > ,
464468 or just good 'ol < a href ="http://rake.rubyforge.org/ "> Rake</ a > ,
465469 it shouldn't be too hard to add a step that calls the < tt > jammit</ tt > command.
466- For an example Jammit setup under Capistrano and Apache, see
467- < a href ="http://afreshcup.com/home/2010/1/18/notes-on-using-jammit-with-rails.html "> Mike Gunderloy's blog post</ a > .
468470 </ p >
469471
470472 < h2 id ="expires "> Expires Headers</ h2 >
@@ -697,6 +699,24 @@ <h2 id="jst">JavaScript Templates</h2>
697699
698700 < h2 id ="changes "> Change Log</ h2 >
699701
702+ < p >
703+ < b class ="header "> 0.6.3</ b > — < small > < i > May 26, 2011</ i > </ small > < br />
704+ Quick bugfix release for Rails 3.1 compatibility, which changes the method
705+ signatures of < tt > javascript_include_tag</ tt > and < tt > stylesheet_link_tag</ tt >
706+ in a backwards-incompatible fashion.
707+ </ p >
708+
709+ < p >
710+ < b class ="header "> 0.6.1</ b > — < small > < i > May 25, 2011</ i > </ small > < br />
711+ Jammit now supports < b > UglifyJS</ b > as a Java-free alternative to YUI and Closure,
712+ for JavaScript compression.
713+ You can now pass < tt > --packages core,embed,ui</ tt > to the < tt > jammit</ tt >
714+ command, in order to only build a subset of your asset packages.
715+ The built-in JS templating function has been upgraded to the equivalent of
716+ the latest < tt > _.template</ tt > .
717+ Environment-specific settings are now supported in your < tt > assets.yml</ tt > file.
718+ </ p >
719+
700720 < p >
701721 < b class ="header "> 0.6.0</ b > < br />
702722 You can now pass < tt > debug_assets=true</ tt > as a query parameter to debug
0 commit comments