Template class abstract
A Template can be efficiently rendered multiple times with different values.
Constructors
- Template(String source, {bool lenient, bool htmlEscapeValues, String name, PartialResolver? partialResolver, String delimiters})
-
The constructor parses the template source and throws TemplateException
if the syntax of the source is invalid.
Tag names may only contain characters a-z, A-Z, 0-9, underscore, and minus,
unless lenient mode is specified.
factory
Properties
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
render(
dynamic values, StringSink sink) → void -
values
can be a combination of Map, List, String. Any non-String object will be converted using toString(). Null values will cause a TemplateException, unless lenient module is enabled. -
renderString(
dynamic values) → String -
values
can be a combination of Map, List, String. Any non-String object will be converted using toString(). Null values will cause a TemplateException, unless lenient module is enabled. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited