Untitled

mail@pastecode.io avatar
unknown
plain_text
24 days ago
587 B
2
Indexable
Never
import { useState } from 'react'

import './App.css'
import { Route, Routes } from 'react-router-dom'
import LoginPage from './pages/LoginPage'
import PrivateRoute from './components/PrivateRoute'
import DashboardPage from './pages/DashboardPage'

function App() {
  const [count, setCount] = useState(0)

  return (
    <>
    <Routes>
        <Route path="/login" element={<LoginPage />} />
        <Route path="/dashboard" element={<PrivateRoute><DashboardPage /></PrivateRoute>} />
        <Route path="/" element={<LoginPage />} />
      </Routes>
    </>
  )
}

export default App
Leave a Comment