getSystemInfoSync
獲取用戶設備的相關信息
示例代碼:
使用位置:在 JS文件的任意函數中使用
const res = wx.getSystemInfoSync(); console.log(res); console.log(res.model); // 設備機型 console.log(res.system); // 設備系統
獲取用戶設備的相關信息
示例代碼:
使用位置:在 JS文件的任意函數中使用
const res = wx.getSystemInfoSync(); console.log(res); console.log(res.model); // 設備機型 console.log(res.system); // 設備系統
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。