"use client"; import { useFeatureIsOn } from "@growthbook/growthbook-react"; import { useEffect } from "react"; import { useSupabase } from "@/lib/context/SupabaseProvider"; import { redirectToPreviousPageOrChatPage } from "@/lib/helpers/redirectToPreviousPageOrChatPage"; import Features from "./Features"; import Hero from "./Hero"; import { HomeHeader } from "./components"; const HomePage = (): JSX.Element => { const { session } = useSupabase(); useEffect(() => { if (session?.user !== undefined) { redirectToPreviousPageOrChatPage(); } }, [session?.user]); const isNewHomePage = useFeatureIsOn("new-homepage-activated"); if (isNewHomePage) { return ( <>
🚧 New homepage in progress 🚧
); } else { return (
); } }; export default HomePage;