VOOZH about

URL: https://capacitorjs.com/docs/apis/device

⇱ Device Capacitor Plugin API | Capacitor Documentation


Skip to main content
An OutSystems Company →
Version: v8

The Device API exposes internal information about the device, such as the model and operating system version, along with user information such as unique ids.

Install

npminstall @capacitor/device
npx cap sync

Example Plugin Usage

import{ Device }from'@capacitor/device';

constlogDeviceInfo=async()=>{
const info =await Device.getInfo();

console.log(info);
};

constlogBatteryInfo=async()=>{
const info =await Device.getBatteryInfo();

console.log(info);
};

API