SuperSnazzy Sneak Peek: Sass Functions

3 views
Skip to first unread message

Nathan Weizenbaum

unread,
Jul 20, 2008, 11:12:46 AM7/20/08
to ha...@googlegroups.com
Hi folks,

This is actually something I added a while ago, but I guess I forgot to
write a sneak peek for it. Sass now supports functions, with the typical
foo(bar) syntax. Right now there's only one - hsl(), which transforms an
HSL color spec into an RGB color object - but the idea is that there
will eventually be many. Ideas are appreciated.

At the moment, the functions take and return the Sass-script wrapper
Number, String, Color, and so forth objects. This may continue into the
future as well; I don't know. The API is reasonably straightforward,
though, if a little verbose, so if you want to work on your own
functions just add them to Sass::Constant::Functions, and by all means
submit them back as patches.

Enjoy!

- Nathan

rebo

unread,
Jul 20, 2008, 8:07:10 PM7/20/08
to Haml
yey, it took a year but you got there in the end!

:D goodjob
Reply all
Reply to author
Forward
0 new messages