Conditional rendering
The <if>
tag is used for conditional rendering. If the specified condition does not hold the content of the <if>
tag is not evaluated.
html
<if true="item.isActive">
<div>Item is active</div>
</if>
Attributes | Use |
---|---|
true="…" | Render the content only if some variable holds the value true . |
false="…" | Render the content only if some variable holds the value false . |
empty="…" | Render the content only if some variable holds an empty array. |