Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pr/use battery #1394

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

arjunindia
Copy link

@arjunindia arjunindia commented Oct 5, 2023

Hook description

  • useBattery Hook - uses Navigator.getBattery() to get device battery status.

Valid use-case for the hook

  • A full-screen immersive video player which can show a minimal battery status indicator instead of user having to check manually

Checklist

  • Have you read the contribution guidelines?
  • If you are porting a hook from react-use, have you checked Port remaining hooks from react-use #33 and the migration guide
    to confirm that the hook has been approved for porting?
  • Does the code have comments in hard-to-understand areas?
  • Is there an existing issue for this PR?
    • link issue here
  • Have the files been linted and formatted?
  • Have the docs been updated?
  • Have you written tests for the new hook?
  • Have you run the tests locally to confirm they pass?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant