<view bindtap="openActionsheet">打开 Actionsheet</view>
<view>data: </view>
Page({
data: {
},
openActionsheet() {
wx.showActionSheet({
itemList: ['菜单1', '菜单2'],
success(res) {
console.log(res)
this.setData({
data: res
})
}
})
}
})
选择后报了一个setData 未定义的错
我需要在<view>data: </view>
这里接收到选择的菜单, 应该如何实现?
https://developers.weixin.qq....