![1***@qq.com](https://img-cdn-tc.dcloud.net.cn/account/identicon/d89c65e75d24bc10e7bde27a050760f3.png)
- 发布:2024-09-19 10:28
- 更新:2024-12-30 11:27
- 阅读:897
![](http://img-cdn-tc.dcloud.net.cn/uploads/questions/20240919/1edff3f31763b09a7e3b7fbea84d617b.png)
![DCloud_UNI_yuhe](http://img-cdn-tc.dcloud.net.cn/uploads/avatar/002/60/98/28_avatar_mid.jpg?v=1719552003)
在 4.41 alpha 已修复这个问题,uniapp 框架已经不带有警告,如果还有其它警告,是项目中有使用 getSystemInfo 的结果
-
-
回复 蔡cai: 使用uni.getSystemInfoSync,在微信上会透传,使用 wx.getSystemInfoSync ,请避免使用uni.getSystemInfoSync
2025-01-07 11:09
-
使用wx.getSystemInfoSync不也是会警告,可不可以uni.getSystemInfoSync在微信小程序编译为wx.getSystemSetting/wx.getAppAuthorizeSetting/wx.getDeviceInfo/wx.getWindowInfo/wx.getAppBaseInfo的整合体
2025-01-07 11:31
-
// #ifdef MP-WEIXIN
uni.getSystemInfoSync = () => {
return {
...wx.getSystemSetting(),
...wx.getAppAuthorizeSetting(),
...wx.getDeviceInfo(),
...wx.getWindowInfo(),
...wx.getAppBaseInfo()
}
}
// #endif
就是类似这个意思2025-01-07 11:39
-
-