Skip to content

Commit c503e41

Browse files
committed
example for rails 3.1 asset pipeline
1 parent 1088988 commit c503e41

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

README.textile

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,16 @@ h2. Configuration
8585

8686
There is no need to create any configuration by default. If you want some customizations as follows, you need to define <code>config/css_sprite.yml</code> file.
8787

88+
h3. Example for rails 3.1
89+
90+
<pre><code>
91+
engine: css.scss
92+
image_path: app/assets/images
93+
stylesheet_path: app/assets/stylesheets
94+
css_images_path: assets
95+
disable_optimization: true
96+
</code></pre>
97+
8898
h3. ImageType
8999

90100
css_sprite uses RMagick to compose the images by default. It uses PaletteMatteType as default image_type, you can change it to any image_type which RMagick supports.
@@ -154,7 +164,7 @@ suffix:
154164
</code></pre>
155165

156166
<code>engine</code> defines css (default) or sass file to generate.
157-
<code>suffix</code> defines the customization styles for specified images.
167+
<code>suffix</code> defines the customization styles for specified images.
158168
The customization above means if your image filename is button suffixed (e.g. post_button.png), the corresponding class .post_button has the additional style with (outline: 0; border: 0; and so on),
159169
if your image filename is icon suffixed (e.g. twitter_icon.png), the correspondiing class .twitter_icon has the additional style with (text-indent: -9999px; cursor: pointer)
160170

@@ -181,4 +191,4 @@ stylesheet_path: app/stylesheets
181191

182192
**************************************************************************
183193

184-
Copyright (c) 2009 [Richard Huang (flyerhzm@gmail.com)], released under the MIT license
194+
Copyright (c) 2009 - 2012 [Richard Huang (flyerhzm@gmail.com)], released under the MIT license

0 commit comments

Comments
 (0)