diff --git a/src/app/page.tsx b/src/app/page.tsx index ed711b0..910b29e 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -1,31 +1,18 @@ -"use client"; - -import { useEffect } from "react"; -import { useRouter } from "next/navigation"; -import { useAuthStore } from "@/store/authStore"; - -export default function Home() { - const router = useRouter(); - const { isAuthenticated, checkAuth } = useAuthStore(); - - useEffect(() => { - checkAuth(); - }, [checkAuth]); - - useEffect(() => { - if (isAuthenticated) { - router.replace("/dashboard"); - } else { - router.replace("/login"); - } - }, [isAuthenticated, router]); +import PublicLayout from '@/components/public/PublicLayout' +import LandingHero from '@/components/public/landing/LandingHero' +import LandingFeatures from '@/components/public/landing/LandingFeatures' +import LandingStats from '@/components/public/landing/LandingStats' +import LandingRecentPosts from '@/components/public/landing/LandingRecentPosts' +import LandingCTA from '@/components/public/landing/LandingCTA' +export default function HomePage() { return ( -
Loading...
-