at-import / SassyLists

MIT License
276 stars 27 forks source link

empty list #37

Closed mmintel closed 10 years ago

mmintel commented 10 years ago

Hello,

I either couldn't find it or it is not there.. however I am missing a function like "sl-empty" or "is-empty" or something like that. It may look like this:

@function sl-empty($list) {
 @if length($list) == 0 {
    @return true;
  } @else {
  @return false;
 }
}
KittyGiraudel commented 10 years ago

Ouh, good point. I'll add this one. :)

mmintel commented 10 years ago

wow fast answer, thanks!

KittyGiraudel commented 10 years ago

I'll add it tonight if I have time. Else, tomorrow. :)

mmintel commented 10 years ago

I hope you can save some time by merging my pull request ;)

KittyGiraudel commented 10 years ago

There are some things missing so I'll merge it manually tonight. :)

mmintel commented 10 years ago

Oh no, what did I forget?

KittyGiraudel commented 10 years ago

Don't sorry, I'll do it. :)

KittyGiraudel commented 10 years ago

Added in 2.1.0 as well as sl-to-list() (aliased as sl-listify()) and sl-comma-list().