Methods

Class/Module Index [+]

Quicksearch

Compass::SassExtensions::Functions::Enumerate

Public Instance Methods

enumerate(prefix, from, through, separator = nil) click to toggle source
# File lib/compass/sass_extensions/functions/enumerate.rb, line 2
def enumerate(prefix, from, through, separator = nil)
  separator ||= Sass::Script::String.new("-", :string)
  selectors = (from.value..through.value).map{|i| "#{prefix.value}#{separator.value}#{i}"}.join(", ")
  Sass::Script::String.new(selectors)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.