patrickulrich.com/src/pages/NotFound.tsx

28 lines
852 B
TypeScript
Raw Normal View History

2025-04-16 21:43:54 -05:00
import { useLocation } from "react-router-dom";
import { useEffect } from "react";
const NotFound = () => {
const location = useLocation();
useEffect(() => {
console.error(
"404 Error: User attempted to access non-existent route:",
location.pathname
);
}, [location.pathname]);
return (
2025-06-01 16:08:27 -05:00
<div className="min-h-screen flex items-center justify-center bg-gray-100 dark:bg-gray-900">
2025-04-16 21:43:54 -05:00
<div className="text-center">
2025-06-01 16:08:27 -05:00
<h1 className="text-4xl font-bold mb-4 text-gray-900 dark:text-gray-100">404</h1>
<p className="text-xl text-gray-600 dark:text-gray-400 mb-4">Oops! Page not found</p>
<a href="/" className="text-blue-500 hover:text-blue-700 dark:text-blue-400 dark:hover:text-blue-300 underline">
2025-04-16 21:43:54 -05:00
Return to Home
</a>
</div>
</div>
);
};
export default NotFound;