小程序获取用户系统

获取用户所用手机系统

  system() {
    let that = this
    wx.getSystemInfo({
      success(res) {
        if (res.system.substr(0, 3) == "iOS") {
          console.log(res.system.substr(0, 3))
        } else {
          console.log(res.system)
        }
      }
    })
  }

猜你喜欢

转载自blog.csdn.net/weixin_43812068/article/details/85003325