feat: add page profile with orders
This commit is contained in:
@@ -7,6 +7,7 @@ import Shop from "./pages/Shop";
|
||||
import NotFoundPage from "./pages/NotFoundPage";
|
||||
import Contact from "./pages/Contact";
|
||||
import Cart from "./pages/Cart";
|
||||
import Profile from "./pages/Profile";
|
||||
|
||||
const PrivateRoute = ({ children }) => {
|
||||
const token = localStorage.getItem("token");
|
||||
@@ -27,6 +28,7 @@ export default function App() {
|
||||
<Route path="/about" element={<About />} />
|
||||
<Route path="/shop" element={<Shop />} />
|
||||
<Route path="/contact" element={<Contact />} />
|
||||
<Route path="/orders" element={<Profile />} />
|
||||
<Route
|
||||
path="/cart"
|
||||
element={
|
||||
@@ -35,7 +37,6 @@ export default function App() {
|
||||
</PrivateRoute>
|
||||
}
|
||||
/>
|
||||
|
||||
<Route path="*" element={<NotFoundPage />} />
|
||||
</Routes>
|
||||
</BrowserRouter>
|
||||
|
||||
Reference in New Issue
Block a user