This documentation is available as Markdown for AI agents and LLMs. See the full Markdown index or append .md to any documentation URL.
Expo KeepAwake
A React component that prevents the screen from sleeping when rendered.
Android
iOS
tvOS
Web
Included in Expo Go
Recommended version:
~56.0.3
expo-keep-awake provides a React hook that prevents the screen from sleeping and a pair of functions to enable this behavior imperatively.
Installation
Terminal
If you are installing this in an existing React Native app, make sure to install expo in your project.
Usage
Example: hook
Keep Awake hook
Example: functions
Keep Awake functions
API
import * as KeepAwake from 'expo-keep-awake';
No API data file found, sorry!