Skip to content

Commit

Permalink
fix: Splash screen jumps on Android (#2114)
Browse files Browse the repository at this point in the history
Technically the whole app jumps when the status bar is updated. This is some weird RN or expo thing.
  • Loading branch information
NigelBreslaw authored Jul 22, 2024
1 parent ade481f commit f1e9885
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion native/app/Root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ function Root() {
const { width } = useWindowDimensions();
const SCREEN_WIDTH = width;
const stateHydrated = useGGStore((state) => state.stateHydrated);
const appReady = useGGStore((state) => state.appReady);

useEffect(() => {
if (SCREEN_WIDTH) {
Expand All @@ -162,7 +163,7 @@ function Root() {

return (
<GestureHandlerRootView>
<StatusBar barStyle={"light-content"} />
{appReady && <StatusBar barStyle={"light-content"} />}
<NavigationContainer ref={navigationRef} theme={navigationContainerTheme}>
<App />
<Toast />
Expand Down

0 comments on commit f1e9885

Please sign in to comment.