-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathRootCmp.jsx
29 lines (26 loc) · 1.06 KB
/
RootCmp.jsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
const { Route, Routes } = ReactRouterDOM
const Router = ReactRouterDOM.HashRouter
import { AppHeader } from "./cmps/AppHeader.jsx"
import { About } from "./views/About.jsx"
import { Home } from "./views/Home.jsx"
import { MailIndex } from "./apps/mail/views/MailIndex.jsx"
import { MailDetails } from "./apps/mail/views/MailDetails.jsx"
import { NoteIndex } from "./apps/note/views/NoteIndex.jsx"
import { NoteEdit } from "./apps/note/views/NoteEdit.jsx"
export function App() {
return (
<Router>
<section className="app">
<AppHeader />
<Routes>
<Route path="/" element={<Home />} />
<Route path="/:default" element={<Home />} />
<Route path="/mail" element={<MailIndex />} />
<Route path="/mail/:mailId" element={<MailDetails />} />
<Route path="/note" element={<NoteIndex />} />
<Route path="/note/:noteId" element={<NoteEdit />} />
</Routes>
</section>
</Router>
)
}