7

Recently i read the http://css-tricks.com/sass-vs-less/ post and one paragraph call my attention, related to CSS3 Helping

So what this comes down to is: Sass has Compass and LESS does not. But it goes deeper than that. The attempts at creating a real robust project like Compass for LESS haven't succeeded because the LESS language isn't robust enough to do it properly. Winner: Sass

One of the robustness explanations says:

Sass has actual logical and looping operators in the language. if/then/else statements, for loops, while loops, and each loops. No tricks, just proper programming. While guarded mixins are a pretty cool, natural concept, language robustness goes to Sass. This language robustness is what makes Compass possible.

I feel uncomfortable with such kind of affirmation and have my doubts. This days almost everything is possible with Javascript (LESS compiler).

Question:
It's possible to build a Compass like tool on top of LESS or the language (JS) isn't robust enough like the post says ??

Note:
The answer should be focus in the fact that LESS is or isn't robust enough to build a Compass like tool rather than your personal preference in the subject. Focus on why (language facts) you do that kind of affirmation.

rink.attendant.6
  • 44,500
  • 61
  • 101
  • 156
Javier Cadiz
  • 12,326
  • 11
  • 55
  • 76
  • Is there a programming question here? SO is not the place for discussing opinion. – cimmanon Jun 17 '13 at 01:37
  • 1
    @cimmanon I edit to clarify my question. I expect a related programming answer like "LESS is not capable of that because X or Y". Please feel free to edit if you have any correction. Thanks – Javier Cadiz Jun 17 '13 at 02:26
  • Your updated question isn't any better than the original. You're essentially asking a yes/no question. If JavaScript/LESS was up for the task, the answer would be well out of scope of of what's reasonable to answer on SO. You may as well have asked "how do I write a webserver" or "how do I write my own browser". – cimmanon Jun 17 '13 at 12:28
  • @cimmanon Created a quick note to clarify and avoid the yes/no question. If isn't sufficient i'll probably remove the question. – Javier Cadiz Jun 17 '13 at 17:34
  • You do understand that Compass is not written in Sass, right? It is written in Ruby. Whether or not LESS is a robust language is irrelevant because you wouldn't be writing your Compass clone in LESS, you'd be writing it in JavaScript or some other language that has a LESS compiler. This is still a question of confirming/denying someone else's opinion. – cimmanon Jun 17 '13 at 17:56

3 Answers3

10

LESS has it (robustness) too

lolmaus's answer implies LESS does not have the same things as SASS, so to pattern off his answer, let me simply respond as follows:

LESS has at least one Compass like work in progress through compless, as well as semantic grid systems (lessframework, semantic grid, fractionless), media query manipulation tools (less media query solutions), various built in math and color tools, styling libraries (Bootstrap, 3L, less elements, LESS hat, Clearless), etc.

In short, robustness has nothing to do with it. Both are robust enough. SASS with Compass has perhaps had more attention paid to it (more developments done), but both SASS and LESS have plenty of supporters, and nearly parallel capabilities.

ScottS
  • 71,703
  • 13
  • 126
  • 146
  • 2
    **No it is not**. Compass is not just a library of mixins and functions. Unlike compless, it's an [gem](http://gembundler.com/)-powered ecosystem of extensions. Instead of downlaoding libraries manually, you list extensions (and optionally desired versions) in `Gemfile`, run `bundle install` and have them available immediately. Many Compass extensions are also far more advanced than their LESS competiros. No grid framework is as versatile and functional as Singularity, and less-media-queries is a laughing stock compared to the power of Breakpoint and Breakpoint Slicer. – Andrey Mikhaylov - lolmaus Jun 18 '13 at 08:28
  • 3
    @lolmaus: the question is not about the quality of extensions that have been created using SASS/LESS, nor about how distribution is done, nor about Compass itself (which, as Cimmamon noted is not directly related to either... that is, its written in Ruby). The question is whether LESS is robust enough to have a Compass like tool built for it. It could, but no one has yet done it to that extent. You seem to be mixing up the robustness of Compass when what is to be compared is the robustness of SASS and LESS (apart from Compass). – ScottS Jun 18 '13 at 10:51
  • i had addressed that it my original answer (last line). – Andrey Mikhaylov - lolmaus Jun 18 '13 at 10:58
  • You "sort of" addressed it while appearing to slam LESS capablities. And then your first comment in my answer (and I assume the down vote of my answer) indicates you were no longer looking at robustness of SASS/LESS, but of Compass itself. The intent of my answer was simply to counter balance your answer, which seemed too skewed to one side with respect to the "robustness" of what can be done with each. That is all. Whether or not something more Compass like will ever evolve "practically" for LESS is irrelevant, but both theoretically and in capability it could be done (which is the question). – ScottS Jun 18 '13 at 13:34
  • You're correct about that LESS and SASS are equally capable, i withdraw my downvote. But i never said LESS is less capable. What i said is that it lacks infrastructure. Going LESS forces you to reinvent the wheel, install libraries manually into every project and build more scaffolding. Yes, the two languages are equally capable if compared isolated. But two *persons* using different languages have drastically different capabilities. It's you who provided examples of LESS libraries as if LESS infrastructure is comparable to Compass and i hurried to disprove that. – Andrey Mikhaylov - lolmaus Jun 18 '13 at 14:29
  • I agree LESS infrastructure is not there _like for SASS_, and especially SASS through Compass. But that was a given based on the question (the OP already recognizes there is not such infrastructure, but questioned LESS capability). Since the question itself revolved around whether such infrastructure could be made for LESS, my examples were showing that some similar (not identical) functionalities are already present as a proof that something more like Compass _could_ be done if a core set of people were compelled to do so. I believe we have similar ideas, approached from differing angles. – ScottS Jun 18 '13 at 15:14
  • let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/31968/discussion-between-lolmaus-and-scotts) – Andrey Mikhaylov - lolmaus Jun 18 '13 at 19:44
4

It is the ecosystem of numerous Compass extensions for all possible purposes that makes SASS really shine.

We have semantic grid systems (Singularity, Susy, Neat, Zen Grids...), media query manipulation tools (Breakpoint, Breakpoint Slicer...), various math and color tools (Toolkit, Modular Scale, Responsive Calculator, Color Schemer, Blend Modes...), styling libraries (Compass, Bourbon, Foundation, Sassy Buttons...), etc.

With SASS, you don't have to build scaffolding or reinvent the wheel over and over again.

Here's an example of a responsive gallery grid: http://sassbin.com/gist/5670191/ Can you solve the task with that little code in LESS?

> It's possible to build a Compass like tool on top of LESS or the language isn't robust enough like the post says ??

Theoretically, there are no limits to do that. Practically, no one would bother because there's the Compass ecosystem already.

Andrey Mikhaylov - lolmaus
  • 23,107
  • 6
  • 84
  • 133
0

I did some reading on blogs and things that I believe to be reliable resources and ultimately decided on SASS. The bottom line is whether or not the language that the compiler/interpreter is based on is robust and powerful only means that the capability to make a better compiler/interpreter which can process a more robust input language may be there, but it in no way indicates that this is the case. I use SASS and I enjoy it. You could debate the merits of apples and oranges for days, but ultimately you need to find the one that works best for you.