@nunosav/no-sleep
v1.0.1
Published
Capacitor 3 plugin to keep mobile device awake
Downloads
2
Readme
@nunosav/no-sleep
Capacitor 3 plugin to keep mobile device awake. Based on https://github.com/capacitor-community/keep-awake but with Capacitor 3 support.
Install
npm install @nunosav/no-sleep
npx cap sync
API
stayAwake()
stayAwake() => Promise<void>
Keep mobile device screen on, preventing idle shutdown.
sleep()
sleep() => Promise<void>
Allow the mobile device screen to go idle.