Skip to content

Commit

Permalink
Merge pull request #56 from Arquisoft/feat/webapp/routing-rewrite
Browse files Browse the repository at this point in the history
chore: webapp routing rewrite
  • Loading branch information
gony02 authored Mar 1, 2024
2 parents 619d2f8 + 023c225 commit ac1c3f4
Showing 1 changed file with 6 additions and 24 deletions.
30 changes: 6 additions & 24 deletions webapp/src/components/Router.jsx
Original file line number Diff line number Diff line change
@@ -1,28 +1,10 @@
import React from "react";
import Root from "../pages/Root";
// import Login from "../pages/Login";
// import Register from "../pages/Register";
import Layout from "./Layout";
import { Route, createBrowserRouter, createRoutesFromElements } from "react-router-dom";

const router = [
{
path: "/",
element: <Layout />,
children: [
{
path: "/",
element: <Root />,
}
// },{
// path: "/login",
// element: <Login />
// },
// {
// path: "/register",
// element: <Register />
// }
]
}
];

export default router;
export default createRoutesFromElements(
<Route path="/" element={<Layout />} >
<Route index element={<Root />} />
</Route>
)

0 comments on commit ac1c3f4

Please sign in to comment.