Blogue da Sass
Página 7 de 8
-
Sass 3.5 Release Candidate
Publicado 30 August 2016 por
I’ve just pushed the button to release Sass 3.5.0-rc.1. If it seems like it’s been a while since the last release, that’s true! But there’s a good reason. We decided to enter feature freeze after the 3.5 release to give libsass, the super-speedy C++ implementation of Sass, time to reach feature parity with Sass 3.4. Libsass is much younger than Sass, and C++ is generally a slower language to work in than Ruby, so this took some time. But it paid off: libsass is now almost 100% compatible with Ruby Sass, differing only in a few small bugs.
After the feature freeze lifted, we were primarily focused on designing the new module system that will be the central feature of Sass 4.0. But we also found some time to add some new features, which are the focus of this release.
CSS Custom Property SupportCSS Custom Property Support permalink
Sass 3.5 now fully supports CSS custom properties. These posed a particular challenge for us, since the custom property…
-
Dropping Support For Old Ruby Versions
Publicado 24 May 2016 por
You may not know Marcel Greter, but you almost certainly know his work. For more than two years, he has been the #1 contributor on LibSass and is the #2 contributor for the history of the project. His monumental efforts, together with Michael Mifsud, are what has kept LibSass thriving recently and why it has reached feature parity with Ruby Sass and is now used by more users than Ruby Sass every day.
Presently, as we are pivoting to a new development model and release cadence, Marcel has decided it is the best time for him to exit the LibSass core team. We are truly sad to see him go, but we wish him well in all his new endeavors. Please join us in thanking him for all his hard work. You can follow and tweet him @mgreter.
Unfortunately, this leaves the LibSass project with some big shoes to fill. LibSass is a popular project that has more than 1.5 Million downloads a month and as of…
-
Dropping Support For Old Ruby Versions
Publicado 29 February 2016 por
As of version 3.5, Ruby Sass will drop support for Ruby 1.8.7 and Ruby 1.9.3. We will continue to support Ruby 2.0.0 and higher.
Ruby 1.8.7 was retired by the Ruby maintainers in June 2013, and Ruby 1.9.3 was retired in February 2015. Despite that, we continued to maintain support for older versions because Ruby 1.8.7 was installed by default on Mac OS X through Mountain Lion (which was released in July 2012).
There are many users of Sass who aren’t independently users of Ruby. We wanted to minimize the amount of work these users need to do to use Sass, which means letting it run on their machine without also requiring them to install a new language.
That decision wasn’t without costs, though. Most seriously, recent versions of the listen package didn’t support older Ruby versions, and older versions of RubyGems weren’t clever enough to avoid downloading them on incompatible Ruby versions. To work around this, we bundled an older version of
listen
with Sass and used… -
Cleaning Up Interpolation
Publicado 9 December 2015 por
Interpolation—the ability to add variables and other snippets using
#{...}
—is one of the handiest all-purpose features of Sass. You can use it just about everywhere you might need to inject a variable, a function call, or some other expression. In most of those places it just plops the value into the surrounding text. It’s straightforward, easy to understand, and useful, which is exactly what we want from a feature.Unfortunately, that’s only true in most places. For complicated historical reasons, there’s one place where interpolation goes a little bit bananas: inside an expression but outside quotes. Most of the time, it makes sense; if you write
display: -#{$prefix}-box
, you’ll get what you expect. But if any operators like+
are used next to the interpolation, you start to get weird output. For example,$name + #{$counter + 1}
might return an unquoted string containing the textname + 3
.This is really weird behavior. Why does
+
behave differently here than it does everywhere else? Why… -
Sass 3.4 is Released
Publicado 19 August 2014 por
We’ve been trying to increase the pace of Sass releases, and it looks like we’ve succeeded. A mere five months after the release of Sass 3.3, we’re announcing the release of Sass 3.4.0, codename Selective Steve. Faster releases mean fewer major features per release, so there are only two big new things to talk about (although there are plenty of little improvements you can read about in the changelog). As the version name suggests, both of these features have to do with selectors.
Using
&
in SassScriptUsing & in SassScript permalink“SassScript” is what we call the mini-language Sass uses for variables, property values, and so forth. It’s mostly just CSS values, but it also supports custom functions, arithmetic, and so forth. In Sass 3.4, we added support for something new: the parent selector,
&
.Most Sass users will probably recognize
&
from its previous appearances in selectors around the world, where it’s used to explicitly refer to the parent selector. For example, in.parent {...