A different approach

0 views
Skip to first unread message

Sid

unread,
Aug 3, 2009, 2:21:15 AM8/3/09
to LESS - Leaner CSS
Hi,

I'm wondering if the following approach to mixin is better?

If we have the following LESS:

.abc { height: 100px; }
.def { width: 50px; }
.mix {
.abc;
.def;
}

Then may be LESS can translate it to the following CSS:

.abc, .mix { height: 100px; }
.def, .mix { width: 50px; }

As that would be less characters, and it would be what most CSS coder
expect?

But I'm thinking, that will be OK as long as the order is in the right
order, so the following should not be translated that way:

.mix {
.def;
.abc;
}

Note the changed order of .def and .abc.

Sid
Reply all
Reply to author
Forward
0 new messages