Safe Areas & Env Variables
In order to use safe areas, you will need to install the react-native-safe-area-context package by following the instructions. They also rely on wrapping your application in Skyle's Provider.
Usage#
StyleSheet Variables#
One way to access safe areas is by using the insets StyleSheet variable.
Learn more
Env Variables#
Safe areas can be accessed via the env() functional notation. You can also set custom env variables like so:
info
You can also pass functions to these variables.
Configure#
To set custom safe areas, override these env variables: