forked from BeOnAuto/auto-engineer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathNotFound.tsx
More file actions
22 lines (19 loc) · 702 Bytes
/
NotFound.tsx
File metadata and controls
22 lines (19 loc) · 702 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import { useLocation } from 'react-router-dom';
import { useEffect } from 'react';
export const NotFound = () => {
const location = useLocation();
useEffect(() => {
console.error('404 Error: User attempted to access non-existent route:', location.pathname);
}, [location.pathname]);
return (
<div className="min-h-screen flex items-center justify-center bg-gray-100">
<div className="text-center">
<h1 className="text-4xl font-bold mb-4">404</h1>
<p className="text-xl text-gray-600 mb-4">Oops! Page not found</p>
<a href="/" className="text-blue-500 hover:text-blue-700 underline">
Return to Home
</a>
</div>
</div>
);
};