I’m in bare workflow just to make it more clear.
So right now I use :
const LangWrapper = props => {
const [hasLoadedLang, setHasLoadedLang] = useState(false);
useEffect(() => {
((async ()=>{
await sleep(5000);
}))();
}, []);
if(!hasLoadedLang){
return <AppLoading/>
}
return props.children
};
and AppLoding is :
const AppLoading = () => {
useEffect(() => {
SplashScreen.preventAutoHideAsync().catch(() => {});
return () => {
SplashScreen.hideAsync().catch(() => {});
};
});
return <View>
<Text>Hello </Text>
</View>;
};
So now the default splash screen runs then it comes to my screen which has a Hello text in it then the app starts.So I have two splash screens which is stupid.
How can I load the first (default) splash screen into the View so it just looks exactly the same?Or any better way to do this?