mirror of
https://github.com/ReaJason/MemShellParty.git
synced 2026-09-24 07:51:52 +08:00
refactor: use react router
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
import { createBrowserRouter } from "react-router-dom";
|
||||
import { env } from "@/config";
|
||||
import RootLayout from "@/components/layouts/root-layout";
|
||||
import IndexPage from "@/pages";
|
||||
|
||||
export const router = createBrowserRouter(
|
||||
[
|
||||
{
|
||||
path: "/",
|
||||
element: <RootLayout />,
|
||||
children: [
|
||||
{
|
||||
index: true,
|
||||
element: <IndexPage />,
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
{
|
||||
basename: env.BASE_PATH,
|
||||
}
|
||||
);
|
||||
Reference in New Issue
Block a user