proposals
proposals copied to clipboard
Power Mode
Plugin Request
Name: power-mode
Package: @capacitor-community/power-mode
Platform(s)
ios, android
Existing Solutions
Not aware of any
Description
iOS and Android devices can be put into low power / battery saver mode. It would be useful to have access / subscribe to this information in order to avoid doing power intensive tasks. Also, requestAnimationFrame
is throttled to 30fps in this case, so I think it is important to give users an ability to do something in these cases i.e. notify users to why they are seeing throttled performance. This info is not available in web apis
I needed this functionality for a project so just ended up making a plugin. You can view it here: https://github.com/danbunkr/power-mode. If the capacitor community is interested in adding it I'd be happy to help make that happen
This should happen. Perf in low power mode is quite noticeable. It would be great to be able to adapt behaviors in low power mode. I'm surprised this hasn't gotten more traction!