Home Page Customization

This commit is contained in:
Ebube
2023-10-16 21:11:18 +01:00
parent 5f95d857d4
commit 857ef15dd2
5 changed files with 62 additions and 75 deletions
+20
View File
@@ -0,0 +1,20 @@
"use client"
import { useEffect } from "react";
import { useRouter } from "next/router";
const AuthRoute = ({ children }) => {
const router = useRouter();
useEffect(() => {
const isAuthenticated = false;
if (!isAuthenticated) {
router.push("/authentication/sign-in/");
}
}, [router]);
return <>{children}</>;
};
export default AuthRoute;