
3条回答 默认 最新
关注使用的方式错了,这个应该是使用调用api的方式。
官方也有案例
https://developers.weixin.qq.com/miniprogram/dev/api/open-api/user-info/wx.getUserProfile.html
参考:<view bindtap="getUserInfo">获取用户信息</view>getUserInfo() { wx.getUserProfile({ desc: "用于更好的展示。", success: (res) =>{ console.log(res); }, }) }本回答被题主选为最佳回答 , 对您是否有帮助呢?评论 打赏 举报 编辑记录解决 1无用