diff --git a/packages/app/src/App.tsx b/packages/app/src/App.tsx index fc2ddb4..10ee8a5 100644 --- a/packages/app/src/App.tsx +++ b/packages/app/src/App.tsx @@ -1,9 +1,11 @@ import { MainPage } from "./pages/MainPage"; import AboutPage from "./pages/AboutPage"; +import NotFoundPage from "./pages/NotFoundPage"; + import "./styles.css"; import { - HashRouter as Router, // Use HashRouter instead of BrowserRouter + BrowserRouter as Router, Route, Routes, Link, @@ -16,13 +18,12 @@ import { ConnectButton } from "@rainbow-me/rainbowkit"; const App = () => { return ( - +
- } /> - } /> - Not found} /> - Not found} /> + } /> + } /> + } /> {/* Add a catch-all route with path="*" */}
diff --git a/packages/app/src/pages/NotFoundPage.tsx b/packages/app/src/pages/NotFoundPage.tsx new file mode 100644 index 0000000..beb8b0d --- /dev/null +++ b/packages/app/src/pages/NotFoundPage.tsx @@ -0,0 +1,8 @@ +// NotFoundPage.tsx +import React from 'react'; + +const NotFoundPage: React.FC = () => { + return
Page Not Found
; +}; + +export default NotFoundPage; \ No newline at end of file diff --git a/packages/app/vercel.json b/packages/app/vercel.json index 613af03..0133b9e 100644 --- a/packages/app/vercel.json +++ b/packages/app/vercel.json @@ -1,12 +1,8 @@ { - "rewrites": [ + "routes": [ { - "source": "/api/(.*)", - "destination": "https://external-service.com/api/$1" - }, - { - "source": "/(.*)", - "destination": "/" + "src": "/(.*)", + "dest": "/index.html" } ] }