SassString class

A SassScript string.

Strings can either be quoted or unquoted. Unquoted strings are usually CSS identifiers, but they may contain any text.

Inheritance

Constructors

SassString(String text, { bool quotes })
Creates a string with the given text. [...]
factory
SassString.empty({bool quotes })
Creates an empty string. [...]
factory

Properties

hasQuotes bool
Whether this string has quotes.
read-only
sassLength int
Sass's notion of the length of this string. [...]
read-only
text String
The contents of the string. [...]
read-only
asList List<Value>
This value as a list. [...]
read-only, inherited
hasBrackets bool
Whether this value as a list has brackets. [...]
read-only, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
isTruthy bool
Whether the value counts as true in an @if statement and other contexts.
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
separator ListSeparator
The separator for this value as a list. [...]
read-only, inherited

Methods

sassIndexToRuneIndex(Value sassIndex, [ String name ]) int
Converts sassIndex into a Dart-style index into text.runes. [...]
sassIndexToStringIndex(Value sassIndex, [ String name ]) int
Converts sassIndex into a Dart-style index into text. [...]
assertBoolean([String name ]) SassBoolean
Throws a SassScriptException if this isn't a boolean. [...]
inherited
assertColor([String name ]) SassColor
Throws a SassScriptException if this isn't a color. [...]
inherited
assertFunction([String name ]) SassFunction
Throws a SassScriptException if this isn't a function reference. [...]
inherited
assertMap([String name ]) SassMap
Throws a SassScriptException if this isn't a map. [...]
inherited
assertNumber([String name ]) SassNumber
Throws a SassScriptException if this isn't a number. [...]
inherited
assertString([String name ]) SassString
Throws a SassScriptException if this isn't a string. [...]
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
sassIndexToListIndex(Value sassIndex, [ String name ]) int
Converts sassIndex into a Dart-style index into the list returned by asList. [...]
inherited
toCssString() String
Returns a valid CSS representation of this. [...]
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited