If someone ends up here with this issue while using nrwl/nx mono-repo for cross-platform build (mobile and web), you need to add the react-native-screens
and react-native-safe-area-context
dependency in the mobile application package.json besides the workspace package.json.