Skip to content

fix(kilo-app): prevent flash of home screen before auth redirect#1465

Merged
iscekic merged 1 commit intomainfrom
fix/welcome-flash
Mar 24, 2026
Merged

fix(kilo-app): prevent flash of home screen before auth redirect#1465
iscekic merged 1 commit intomainfrom
fix/welcome-flash

Conversation

@iscekic
Copy link
Contributor

@iscekic iscekic commented Mar 24, 2026

Summary

  • Fixed splash screen flash showing "Welcome to Kilo!" before redirecting anonymous users to the login screen
  • Root cause: <Slot /> rendered the (app) route and SplashScreen.hideAsync() fired while router.replace to login was still in flight
  • Fix: compute redirect need synchronously, gate <Slot /> rendering on it, and only hide splash screen once the user is on the correct route group

Test plan

  • Open app as anonymous user — should see splash screen then login, no flash of home screen
  • Open app as authenticated user — should see splash screen then home screen directly
  • Sign out — should redirect to login without flash
  • Sign in — should redirect to home without flash

Splash screen was hidden and <Slot /> rendered the (app) route while
router.replace to the login screen was still in flight. Compute
redirect need synchronously, gate rendering on it, and only hide the
splash screen once the user is on the correct route group.
@iscekic iscekic self-assigned this Mar 24, 2026
@kilo-code-bot
Copy link
Contributor

kilo-code-bot bot commented Mar 24, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (1 files)
  • kilo-app/src/app/_layout.tsx

Reviewed by gpt-5.4-20260305 · 149,092 tokens

@iscekic iscekic merged commit 2240c2b into main Mar 24, 2026
19 checks passed
@iscekic iscekic deleted the fix/welcome-flash branch March 24, 2026 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants