capacitor-temperature
TypeScript icon, indicating that this package has built-in type declarations

0.0.1 • Public • Published

capacitor-temperature

The DeviceTemperature is a Capacitor plugin that provides an easy-to-use interface to access the current temperature of the user's device.

Install

npm install capacitor-temperature
npx cap sync

API

getTemperature()

getTemperature() => Promise<{ temperature: number; }>

Returns: Promise<{ temperature: number; }>


addListener('temperatureUpdate', ...)

addListener(eventName: 'temperatureUpdate', listenerFunc: (data: { temperature: number; }) => void) => PluginListenerHandle
Param Type
eventName 'temperatureUpdate'
listenerFunc (data: { temperature: number; }) => void

Returns: PluginListenerHandle


Interfaces

PluginListenerHandle

Prop Type
remove () => Promise<void>

/capacitor-temperature/

    Package Sidebar

    Install

    npm i capacitor-temperature

    Weekly Downloads

    0

    Version

    0.0.1

    License

    MIT

    Unpacked Size

    24.3 kB

    Total Files

    27

    Last publish

    Collaborators

    • nishantonline1