A few months back I discovered the concept of CSS pre-processors. At that time I knew about LESS and Sass and had to decide which one was the best option for me. I thought the concept was really cool but lacked a real project to start getting my hands dirty with it.

Then I started working on a freelance project and Crunch came out; I was sold. This app made me choose LESS over Sass, which may not be the best of reasons, but it seems like I’m not the only one to pick this language. As you may know the second iteration of Twitter Bootstrap also relies on LESS, even encouraging you to use Crunch.

Saturday @ilovetypography tweeted this:

Dreaming of something that takes my CSS & LESSifies it — automagically.

To which I replied that:

This seems possible! Will try and see if I can write such a tool, interesting idea…

Sunday morning I started writing JavaScript, and a few hours later I had a good-looking script. Took some time to create a simple yet efficient UI, and that was it. Least.

The tool takes basic CSS as an input and tries its best to output the LESS or Sass source it would correspond to (including nesting, classes and pseudo-classes). I also added an option to output something for the not-so-popular-but-interesting Stylus language.

As you’ll notice in the footer of the tool’s page it’s a “five-hour project”. In order to have a decent UI as fast as possible I used Twitter Bootstrap, which has its downsides but fits perfectly this kind of projects. A “five-hour project” also means it may still be a bit buggy. Don’t hesitate to ping me on Twitter or to drop comments here.

ps: Least both references LESS and “To Say the Very Least”, a track by Buck 65 on Vertex. Ah!