ListItem
The item template of aList. It renders no structure of its own; it only repeats its inner root element once per item.
Signature
Rules
Scope
InsideListItem:
{Item.*}: the current array item{Index}: the current index, 0-based
List.As:
Runtime behavior
Listrepeats theListItemroot element once per array entry.- Each instance has its own
Item/Indexscope. - There is no selection state, divider, or click event; put a
Button/Linkinside the item, or add aDivider. Datainside the item template still belongs to the component’s global scope; it is not a per-item data source.
Example
Gotchas
- Bare text cannot go directly inside
ListItem; useText.Valueor the content syntax ofText. OnClickon aButtoninside an item can bind values from the current item, such as{Item.Url}.