<button open-type="getUserInfo" bindgetuserinfo="getuserinfo">获取用户信息</button>
// pages/login/login.js Page({ data: { }, onl oad(options) { }, getuserinfo(e){ console.log(e) let userInfo = e.detail.userInfo wx.setStorageSync('userInfo', userInfo) wx.navigateBack({ delta:1, }) } })
标签:用户,信息,获取,userInfo,login,wx From: https://www.cnblogs.com/yhgz/p/17779874.html