by Before Semicolon


if attribute details
name if
type attribute
value executed; Condition or value that resolves to truthy, falsy, TRUE or FALSE.
related attributes none
description An attribute that takes some logic as value and decides whether to render the tag or not.

Usage Examples

<p #if="count > 1">There are {count} items available.</p>
<p #if="count === 1">There is 1 item left.</p>
<p #if="count === 0">There are no more items left.</p>
<div #if="$data.description">