Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

capacitor-timer-notification

Package Overview
Dependencies
Maintainers
0
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

capacitor-timer-notification

timer notifcation

  • 0.1.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
24
decreased by-76.47%
Maintainers
0
Weekly downloads
 
Created
Source

capacitor-timer-notification

A Capacitor plugin to create a timer notification that displays a countdown timer in the notification bar.

Usage

Add the following to your android/app/src/main/AndroidManifest.xml file to declare the necessary permissions and service:

<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/>
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_MEDIA_PLAYBACK" />

<service
  android:name=".TimerService"
  android:enabled="true"
  android:exported="false"
  android:foregroundServiceType="mediaPlayback"/>




## Install

```bash
npm install capacitor-timer-notification
npx cap sync

API

  • startTimer(...)
  • stopTimer()
  • getRemainingTime()

startTimer(...)

startTimer(options: { duration: number; }) => Promise<void>
ParamType
options{ duration: number; }

stopTimer()

stopTimer() => Promise<void>

getRemainingTime()

getRemainingTime() => Promise<number>

Returns: Promise<number>


Keywords

FAQs

Package last updated on 17 Nov 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc