15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
- 发布:2020-09-09 15:29
- 更新:2020-09-11 15:02
- 阅读:790
产品分类: uniapp/小程序/微信
PC开发环境操作系统: Mac
PC开发环境操作系统版本号: 10.3
HBuilderX类型: 正式
HBuilderX版本号: 2.8.11
第三方开发者工具版本号: 1.03
基础库版本号: 000000
项目创建方式: HBuilderX
示例代码:
操作步骤:
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
预期结果:
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
实际结果:
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker> ```
bug描述:
rightText="{{sex[index]}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:16:46.116 9 | <uni-list>
15:16:46.116 10 | <picker @change="bindPickerChange" :value="index" :range="sex">
15:16:46.123 11 | <uni-list-item title="性别" showArrow="true" rightText="{{sex[index]}}"> </uni-list-item>
15:16:46.123 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:16:46.128 12 | </picker>
之前编译正常
c***@sohu.com (作者)
已解决 属性绑定不能使用
<image src = "{{img_src}}"></image>
只能使用bind 的形式
<image v-bind:src = "image_src"> / <image :src = "image_src">