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

Keep screen awake when viewing recipe #1469

Merged
merged 1 commit into from
Feb 7, 2022
Merged

Keep screen awake when viewing recipe #1469

merged 1 commit into from
Feb 7, 2022

Conversation

benscobie
Copy link
Contributor

To resolve #1434

This is rather basic, at some point you could add a switch to toggle this functionality on & off.

@vabene1111
Copy link
Collaborator

awesome, thanks for implementing this. I need to review this since i dont know much about this function but i am pretty sure it should work. Since i have my phone never turn off i never even noticed that this is a problem 😂

@vabene1111
Copy link
Collaborator

ok just checked the vue lifecylcle docs, beforeUnmount seems to be a vue 3 lifecycle hook so i changed that to beforeDEstory, otherwise this seems correct, thanks for the contribution!

@vabene1111 vabene1111 merged commit 5f9820e into TandoorRecipes:develop Feb 7, 2022
@vabene1111
Copy link
Collaborator

ok it appears that this is indeed available in v2 as well but not in the docs .. ok staying with unmount then ..

@benscobie benscobie deleted the issue/1434 branch February 7, 2022 18:14
@ccoenen
Copy link

ccoenen commented Feb 8, 2022

it should be noted that there is limited browser support for navigator.wakeLock (MDN, caniuse). Neither mobile firefox nor iOS Safari support this. So the only benefit is to Chrome users on android.

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

Successfully merging this pull request may close these issues.

Prevent switching display off after OS timeout
3 participants