Compress css files with Rails

Hi,
I work on a website with many css files. To improve the performance of
the site I would to merge all my css file into one on the production
site.
I know I could do this using plugins, but I heard it is possible
natively within rails.

Does someone know what it is?
Greg

Am 04.06.2010 um 10:37 schrieb Gregory Ma:

I work on a website with many css files. To improve the performance of
the site I would to merge all my css file into one on the production
site.
I know I could do this using plugins, but I heard it is possible
natively within rails.

Does someone know what it is?

See the :cache => true option of stylesheet_link_tag

Felix

stylesheet_link_tag with the :cache option.

Cheers,

Andy


Andy J.
http://andyjeffries.co.uk/ #rubyonrails #mysql #jquery
Registered address: 64 Sish Lane, Stevenage, Herts, SG1 3LS
Company number: 5452840

See the :cache => true option of stylesheet_link_tag
ActionView::Helpers::AssetTagHelper

You don’t have to use true either - you can use a string (so if you have
more than one layout each using a different set of stylesheets you can
create individual cache files for each layout).

Cheers,

Andy

Felix Schäfer wrote:

Am 04.06.2010 um 10:37 schrieb Gregory Ma:

I work on a website with many css files. To improve the performance of
the site I would to merge all my css file into one on the production
site.
I know I could do this using plugins, but I heard it is possible
natively within rails.

Does someone know what it is?

See the :cache => true option of stylesheet_link_tag
ActionView::Helpers::AssetTagHelper

Felix

Thank you very much

Greg Ma wrote:

Is there an option to remove all useless content in the files? such as
comments.

If you use Sass (which I highly, highly recommend) then this is done for
you. You get lots of other advantages too.

Best,

Marnen Laibow-Koser
http://www.marnen.org
[email protected]

Marnen Laibow-Koser wrote:

If you use Sass (which I highly, highly recommend) then this is done for
you. You get lots of other advantages too.

Best,

Marnen Laibow-Koser

What is Saas?

On 04 Jun 2010, at 14:46, Greg Ma wrote:

What is Saas?
http://sass-lang.com/

Best regards

Peter De Berdt

Peter De Berdt wrote:

On 04 Jun 2010, at 14:46, Greg Ma wrote:

What is Saas?
http://sass-lang.com/

Best regards

Peter De Berdt

Wow Saas looks pretty cool!

Is there an option to remove all useless content in the files? such as
comments.