diff --git a/src/app/not-found.tsx b/src/app/not-found.tsx index 2e7c748b8..2e1f919ef 100644 --- a/src/app/not-found.tsx +++ b/src/app/not-found.tsx @@ -1,39 +1,41 @@ 'use client'; -import Link from 'next/link'; +import { useRouter } from 'next/navigation'; +import { useEffect } from 'react'; export default function GlobalError() { + const router = useRouter(); + useEffect(() => { + // Set the title dynamically + document.title = '404: Page could not be found'; + }, []); + const handleClick = () => { + document.title = + 'Take your development skills from 0 to 100 and join the 100xdevs community'; + router.push('/'); + }; return ( - -
-Oops! Page Not Found.
-Oops! Page Not Found.
+