Method: SassC::Script::Value#with_contents

Defined in:
lib/sassc/script/value.rb

#with_contents(contents, separator: self.separator, bracketed: self.bracketed) ⇒ Sass::Script::Value::List

Creates a new list containing ‘contents` but with the same brackets and separators as this object, when interpreted as a list.

Parameters:

  • contents (Array<Value>)

    The contents of the new list.

  • separator (Symbol) (defaults to: self.separator)

    The separator of the new list. Defaults to #separator.

  • bracketed (Boolean) (defaults to: self.bracketed)

    Whether the new list is bracketed. Defaults to #bracketed.

Returns:

  • (Sass::Script::Value::List)


123
124
125
# File 'lib/sassc/script/value.rb', line 123

def with_contents(contents, separator: self.separator, bracketed: self.bracketed)
  SassC::Script::Value::List.new(contents, separator: separator, bracketed: bracketed)
end