import { Redirect } from 'expo-router'
import { useAuth } from 'src/state/AuthProvider'

export default function Index() {
  const { user, isLoading } = useAuth()
  if (isLoading) return null
  return <Redirect href={user ? '/(auth)/(tabs)/home' : '/(public)/login'} />
}
