navigation login and signup
This commit is contained in:
@@ -1,12 +1,25 @@
|
||||
import './App.css'
|
||||
import { LoginPage } from './pages/Login'
|
||||
import { SignUp } from './pages/SignUp'
|
||||
import { AuthLayout } from './layouts/AuthLayout'
|
||||
import { Routes, Route, Navigate } from 'react-router'
|
||||
|
||||
|
||||
function App() {
|
||||
|
||||
return (
|
||||
<>
|
||||
<LoginPage className="flex min-h-svh flex-col items-center justify-center bg-background text-foreground" />
|
||||
</>
|
||||
<Routes>
|
||||
<Route path="/" element={<Navigate to="/auth/login" replace />} />
|
||||
|
||||
<Route path="/auth" element={
|
||||
<AuthLayout className="flex min-h-svh flex-col items-center justify-center bg-background text-foreground" />
|
||||
}>
|
||||
<Route path="login" element={<LoginPage />} />
|
||||
<Route path="signup" element={<SignUp />} />
|
||||
</Route>
|
||||
|
||||
<Route path="*" element={<Navigate to="/auth/login" replace />} />
|
||||
</Routes>
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user