class Sass::Tree::Node

def children_to_src(tabs, opts, fmt)

Returns:
  • (String) - The Sass or SCSS code corresponding to the children

Parameters:
  • fmt (Symbol) -- `:sass` or `:scss`
  • opts ({Symbol => Object}) -- An options hash (see {Sass::CSS#initialize})
  • tabs (Fixnum) -- The amount of tabulation to use for the Sass code
def children_to_src(tabs, opts, fmt)
  return fmt == :sass ? "\n" : " {}\n" if children.empty?
  (fmt == :sass ? "\n" : " {\n") +
    children.map {|c| c.send("to_#{fmt}", tabs + 1, opts)}.join.rstrip +
    (fmt == :sass ? "\n" : " }\n")
end