{less} is more...

I came across this awesome tool today and thought I would share my experience with others...

 

 

3 Steps to writing {less}

1. Setup
1.1 Install the less Ruby gem by opening up "Terminal" and typing in one line.

   
Click here to download:
less-is-more-pguqFAFoxymjlHmGpJIv.zip (1162 KB)

1.2 Download the {less}.app.

 

 

2. {less} App Usage

 2.1 Drag your css folder into the "Watched Folders" section.

   
Click here to download:
less-is-more-yxitptxnafpFwfunBpgJ.zip (829 KB)

2.2 Switch to the "Compiler" tab and turn on "Automatically compile files when saved".

Coda Side-Note: There is a {less} plugin for Coda if ya don't mind first having to create a "Site" in your sites section first.

 

 

3. {less} Usage
3.1 Overview

Basic workflow of {less}:
1. Edit ".less" files.
2. Save file -> as you save, the {less}.app automatically generates the ".css" file.
Tip: If you have Growl, it will notify you when it has finished.
3. Review your web page.
My demo site is structured and looks like so:

   
Click here to download:
less-is-more-gCvgDphFhbIDqsvFweeq.zip (591 KB)

 

3.1 Import & Variables

* You can start to create reusable CSS libraries by using the "@import" syntax.

   
Click here to download:
less-is-more-AxjigAvdbutfDkhaIvoy.zip (129 KB)

* Variables can be used to store CSS attribute values to be reused throughout your project so as to alleviate the trouble with core changes.

   
Click here to download:
less-is-more-paigDkuEtaGqJGwApjdv.zip (27 KB)

 

3.2 "Mixins"

Yeah, it doesn't automatically mix sense just yet, but it's quite simple actually...

I would like my ".panel" class to have rounded corners; so I'm going to "mix" or add the rounded corners styling by simply adding its CSS class name (".rounded-corners") to my ".panel" class:

     
Click here to download:
less-is-more-yewJhpyllcnfvDiutcHD.zip (79 KB)

 

3.3 "Nesting stuff"

You can basically use this to nicely organize your CSS and type less ( excuse the pun ); I only have one item nested but imagine if you had more!...

   
Click here to download:
less-is-more-uvyFHjysxDCCdjFkxiuI.zip (48 KB)

 

3.4 Operations

If you got a special magic formula, you can implement it with basic operations even if there is a unit of measurement (e.g. px, em, etc.).

 

 

All The Files


Summary

{less} is a pretty neat addition to any web designer/developers arsenal.

I left out "Namespaces & Accessors" and a little more as I always believe that one should have at least one look at the official docs... you can find all the {less} techniques here: http://lesscss.org/docs.

Hope this has helped you on your way to writing {less}; until next time, keep writing more, or {less}. :D

 

TM

Awesomeness lies in the hands of the brave.

Filed under  //   Awesomeness   CSS   less app   review   ruby gem   Tool   tutorial   {less}   {less} is more  
Left behind on June 18, 2010
// 0 Comments

a must for web dev's... #HTML #CSS #Hi-Speed #Zen_Coding #2010

Can't believe I didn't find this sooner!

So for those who don't already have it, enjoy and Happy 2010!


 

Here it ishttp://code.google.com/p/zen-coding/

List of the HTML Elements Shortcuts: http://code.google.com/p/zen-coding/wiki/ZenHTMLElementsEn

List of the HTML Selector Shortcuts: http://code.google.com/p/zen-coding/wiki/ZenHTMLSelectorsEn

List of the CSS Shortcuts: http://code.google.com/p/zen-coding/wiki/ZenCSSPropertiesEn 


TM

"May 2010 usher in a new world of possibilities!"

Filed under  //   Coding   CSS   Hi-Speed   HTML   IDE   Tool   Video   Web Developer   Zen_Coding  
Left behind on January 1, 2010
// 0 Comments