await console.log('设备用户代理:', DeviceInfo.getUserAgent()); await console.log('设备(APP)版本:', DeviceInfo.getVersion()); // await console.log('用户偏好是否设置为24小时格式:', DeviceInfo.is24Hour()); await console.log('程序是否允许在模拟器中:', DeviceInfo.isEmulator()); await cons...
iPhone 6console.log("User Agent",DeviceInfo.getUserAgent());// e.g. Dalvik/2.1.0 (Linux; U; Android 5.1; Google Nexus 4 - 5.1.0 - API 22 - 768x1280 Build/LMY47D)console.log("Device Locale",DeviceInfo.getDeviceLocale());// e.g en-USconsole.log("Device Country",DeviceInfo.get...
console.log("Build Number", DeviceInfo.getBuildNumber()); // e.g. 89 console.log("App Version", DeviceInfo.getVersion()); // e.g. 1.1.0 console.log("App Version (Readable)", DeviceInfo.getReadableVersion()); // e.g. 1.1.0.89 console.log("Device Name", DeviceInfo.getDeviceName(...
console.log("Build Number", DeviceInfo.getBuildNumber()); // e.g. 89 console.log("App Version", DeviceInfo.getVersion()); // e.g. 1.1.0 console.log("App Version (Readable)", DeviceInfo.getReadableVersion()); // e.g. 1.1.0.89 console.log("Device Name", DeviceInfo.getDeviceName(...
getVersion() string ✅ ✅ ✅ ❌ getBrightness() Promise<number> ✅ ❌ ❌ ❌ hasGms() Promise<boolean> ❌ ✅ ❌ ❌ hasHms() Promise<boolean> ❌ ✅ ❌ ❌ hasNotch() boolean ✅ ✅ ✅ ❌ hasSystemFeature() Promise<boolean> ❌ ✅ ❌ ❌ isAirplaneMod...
Exampleslet version = DeviceInfo.getVersion(); // iOS: "1.0" // Android: "1.0" or "1.0.2-alpha.12" // Windows: ?isAirplaneMode()Tells if the device is in Airplane Mode.ExamplesDeviceInfo.isAirplaneMode().then((airplaneModeOn) => { // false });...
console.log("App Version", DeviceInfo.getVersion()); // e.g. 1.1.0 console.log("App Version (Readable)", DeviceInfo.getReadableVersion()); // e.g. 1.1.0.89 console.log("Device Name", DeviceInfo.getDeviceName()); // e.g. Becca's iPhone 6 ...
getVersion() string ✅ ✅ ✅ ❓ ❌ getBrightness() Promise<number> ✅ ❌ ❌ ❓ ❌ hasGms() Promise<boolean> ❌ ✅ ❌ ❌ ❌ hasHms() Promise<boolean> ❌ ✅ ❌ ❌ ❌ hasNotch() boolean ✅ ✅ ✅ ❓ ❌ hasDynamicIsland() boolean ✅ ✅ ✅...
getVersion() string ✅ ✅ ✅ ❌ ✅ getBrightness() Promise<number> ✅ ❌ ❌ ❌ ❌ hasGms() Promise<boolean> ❌ ✅ ❌ ❌ ❌ hasHms() Promise<boolean> ❌ ✅ ❌ ❌ ❌ hasNotch() boolean ✅ ✅ ✅ ❌ ✅ hasDynamicIsland() boolean ✅ ✅ ✅...
const version = DeviceInfo.getVersion(); // iOS: "1.0" // Android: "1.0" // Windows: ?is24Hour()Tells if the user preference is set to 24-hour format.Examplesconst is24Hour = DeviceInfo.is24Hour(); // trueisAirPlaneMode()Tells if the device is in AirPlaneMode....