RikuloRikulo

The = Tag

[= expression ]

[= expression, arg1: value1, arg2: value2]

Specifies any Dart expression that will be output to the generated Dart file. For example,

<td><img src="[=info.isDirectory ? 'file.png': 'directory.png']"/></td>

The expression will be converted to string automatically. In additions, the string will be encoded to escape special XML characters, such as & and <. If you prefer to encode it differently you can specify the argument called encode such as:

<a href="/foo?key=[=whatever.value, encode: 'query']">foo</a>

If you prefer not to encode at all, you can specify encode: 'none'. Then, the value will be output directly.

In additions, you can specify additional arguments to control how an expression is output, such as firstLine, maxlength and pre. For more information, please refer to Rsp.nnx().