Text::Sass(3) A Naieve Perl implementation of Sass & SCSS.

VERSION

See Text/Sass.pm

SYNOPSIS


use Text::Sass;
my $sass = Text::Sass->new();
print $sass->sass2css(<<'EOF');
$font-stack: Helvetica, sans-serif
$primary-color: #333
body
font: 100% $font-stack
color: $primary-color
EOF
print $sass->scss2css(<<'EOF');
$font-stack: Helvetica, sans-serif;
$primary-color: #333;
body {
font: 100% $font-stack;
color: $primary-color;
}
EOF

DESCRIPTION

This is a pure perl implementation of Sass and SCSS languages. Currently it implements only a subset of the specification.

Sass project page <http://sass-lang.com>

SUBROUTINES/METHODS

new - Constructor - nothing special

  my $oSass = Text::Sass->new;

css2sass - Translate CSS to Sass

  my $sSass = $oSass->css2sass($sCSS);

sass2css - Translate Sass to CSS

  my $sCSS = $oSass->sass2css($sSass);

scss2css - Translate Scss to CSS

  my $sCSS = $oSass->scss2css($sScss);

DEPENDENCIES

Readonly
Convert::Color

INCOMPATIBILITIES

All variables are currently global. This can be quite unpleasant.

BUGS AND LIMITATIONS

See README

AUTHOR

Roger Pettett <[email protected]>

DIAGNOSTICS

 Set $Text::Sass::DEBUG = 1;

CONFIGURATION AND ENVIRONMENT

Nothing required beyond $DEBUG

LICENSE AND COPYRIGHT

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.10 or, at your option, any later version of Perl 5 you may have available.