device
A tradução desta página não existe ou está desatualizada, por isso é mostrada em inglês. Ler em inglês
Use device metadata for support diagnostics and platform-specific presentation. These fields describe the device and operating system; they are not a stable user identity.
Build a support summary
import { device } from 'kuito';
device.model; // 'iPhone 16 Pro', 'Pixel 8'
device.type === 'tablet';
if (!device.physical) console.log('on a simulator');Behavior and limits
Read osName, osVersion, model, type and physical-device information to explain a bug report. Android-specific fields such as API level do not have equivalent values on every platform. Test capability-dependent features directly rather than inferring availability from a marketing model name.
Continue
Read Window for the related workflow. The API reference lists every method, option, event and return type.
Referência
Exportações 12
Métodos, constantes e tipos expostos por este namespace nativo.
type
DeviceTypeWhat kind of device the app runs on.valuephysicalFalse on a simulator or emulator.valuebrandApple on iOS; the consumer brand on Android, as google.valuemanufacturerThe device's manufacturer, Apple on iOS and Build.MANUFACTURER on Android, read once on first use.valuemodelThe marketing name, as iPhone 16 Pro or Pixel 8; null for an iOS model Kuito doesn't know.valuemodelIdiOS: the hardware identifier, as iPhone17,1.valuetypeWhat kind of device the app runs on: 'phone', 'tablet', 'desktop', 'tv' or 'unknown'.valuememoryBytes of physical memory.valueosNameiOS, iPadOS or Android.valueosVersionThe version of the operating system the app runs on.valueosBuildIdThe operating system's build identifier, or null when the platform does not report one.valueapiLevelAndroid's API level; null on iOS.Gerado a partir das declarações TypeScript públicas: assinaturas, props e predefinições vêm da fonte verificada, as descrições da sua JSDoc. Nenhuma predefinição é inventada.