[Haskell-cafe] Re: [web-devel] statically compiled css
ionfish at gmail.com
Fri Aug 6 05:28:52 EDT 2010
On 6 August 2010 09:19, Michael Snoyman <michael at snoyman.com> wrote:
> After looking into sass a little bit, I've decided I like it ;). I see the
> following benefits of implementing something sass-like in Haskell via
> * Compile-time guarantee of well-formedness.
> * The speed benefits of blaze-builder. Of course, this will still be slower
> than serving a static file.
> * Ability to use the same Haskell variables for both Hamlet and CSS.
> I've started a new repo on Github; I'm tentatively calling the project
This sounds pretty interesting. I wrote a Ruby tool called Stylish 
a couple of years ago to solve a similar set of problems, and have
occasionally wondered about rewriting it in Haskell. I look forward to
seeing what you come up with.
One potentially useful feature is generating code that requires
browser prefixes (-webkit-border-radius etc.). There's also potential
for generating minified versions of the code, concatenating multiple
stylesheets etc.—it's a lot easier to do this stuff if you can
programmatically manipulate the stylesheet at run-time. Embedding
assets (graphics) as data URIs is another thing; have a look at how
something like Jammit  does this.
There's also a Firefox and Thunderbird extension  called Stylish.
Obviously you're free to call your project whatever you wish; I just
thought I should let you know.
More information about the Haskell-Cafe