Skip to content

Instantly share code, notes, and snippets.

@zhangkn
Created May 17, 2018 06:50
Show Gist options
  • Save zhangkn/e6e0396d6b62e7f419e197974fd12403 to your computer and use it in GitHub Desktop.
Save zhangkn/e6e0396d6b62e7f419e197974fd12403 to your computer and use it in GitHub Desktop.
<!-- >``` -->
<!-- >logs.wxml 页面结构 -->
<view class="container log-list">
<!--使用 wx:for-item 可以指定数组当前元素的变量名,默认值为item -->
<block wx:for="{{logs}}" wx:for-item="log">
<!--使用 wx:for-index 可以指定数组当前下标的变量名:默认index-->
<text class="log-item">{{index + 1}}. {{log}}</text>
</block>
</view>
<!-- >``` -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment