I’m using SafeAreaView
from react-native-safe-area-contex
, but it doesn’t seem to be working correctly with Pixel 8 Pro.
Here’s how I used it in the component:
import { Text } from "react-native";
import { useNavigation } from "@react-navigation/native";
import { useLayoutEffect } from "react";
import { SafeAreaView } from "react-native-safe-area-context";
const HomeScreen = () => {
const navigation = useNavigation();
useLayoutEffect(() => {
navigation.setOptions({
headerShown: false
})
});
return (
<SafeAreaView>
<Text>This is some text that shouldn't be hidden behind the camera notch but on Pixel it is</Text>
</SafeAreaView>
)
}
export default HomeScreen
Am I using it incorrectly?