views:

70

answers:

2

I am looking to see if there is an open source/free project that provides a CSS manager. I am looking for this mainly for performance tweaking and hoping there is a readymade project rather than building from scratch. Features I am looking for include:

  1. Combines multiple .css files into a single css file
  2. Optionally minifies the resulting .css file
  3. Works well with .Net (a user control, custom handler, etc)

Is there a project out that that handles this?

+2  A: 

You can try YUICompressor for .Net for the minifying.

We use this on my current project and it works well - it also supports minifying Javascript.

For the aggregating (inlining multiple files into a single file), we ended up rolling our own, as we couldn't find something in .Net that did exactly what we wanted.

Rob Levine
Do you know of an intelligent combiner/parser? I think you can just concat all the files together and it should work, but it would be nice if the combiner could handle overrides from subsequent css files by applying the change back to the original style rather than by including the original and override verbatim.
vfilby
Worth looking into Bundler mentioned by AlexCuse I reckon.
Rob Levine
+2  A: 

Not sure if it does minification, but this project does a great job combining and may be of interest Bundler

AlexCuse
It does do minification as well, using the YUI minifier or JSmin, thanks!
vfilby
awesome, one more reason to love it :)
AlexCuse
+1 - that might replace the bit of "hand rolled" inlining stuff I mentioned in my post below - never come across Bundler before.
Rob Levine