Created
January 28, 2021 08:38
-
-
Save salmanyaqoob/f18bfe87ae83d41ab516674256bf00fa to your computer and use it in GitHub Desktop.
Array screen UI
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <stack class="stack"> | |
| <image src='/common/background.png' class="background"></image> | |
| <div class="container" onswipe="touchMove"> | |
| <text> | |
| Arrays | |
| </text> | |
| <!-- div loop rendering --> | |
| <!--By default, $item indicates the element in the array, and $idx indicates the index of the element in the array.--> | |
| <div for="{{arrayData}}" tid="id" class="containerArray"> | |
| <text>{{$idx}}.{{$item.name}} | |
| </text> | |
| </div> | |
| <!-- Define the name for an element variable. --> | |
| <div for="{{value in arrayData}}" tid="id" class="containerArray"> | |
| <text>{{$idx}}.{{value.name}} | |
| </text> | |
| </div> | |
| <!-- Define an element variable and its index name. --> | |
| <div for="{{(index, value) in arrayData}}" tid="id" class="containerArray"> | |
| <text>{{index}}.{{value.name}} | |
| </text> | |
| </div> | |
| </div> | |
| </stack> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment