Skip to content

Commit 91fb19c

Browse files
authored
Merge pull request #9 from kc3hack/FE-2
[FE-2]Solo.tsxとSolo.cssの作成.localhost/SoloでSolo.tsxに移行.
2 parents 70434e3 + 2da6dcb commit 91fb19c

File tree

5 files changed

+85
-3
lines changed

5 files changed

+85
-3
lines changed

frontend/package-lock.json

Lines changed: 59 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frontend/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@
1111
},
1212
"dependencies": {
1313
"react": "^19.2.0",
14-
"react-dom": "^19.2.0"
14+
"react-dom": "^19.2.0",
15+
"react-router-dom": "^7.13.0"
1516
},
1617
"devDependencies": {
1718
"@eslint/js": "^9.39.1",

frontend/src/Solo/Solo.css

Whitespace-only changes.

frontend/src/Solo/index.tsx

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import './Solo.css'
2+
3+
function Solo() {
4+
5+
return (
6+
<>
7+
<div>
8+
9+
</div>
10+
</>
11+
)
12+
}
13+
14+
export default Solo

frontend/src/main.tsx

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,19 @@
11
import { StrictMode } from 'react'
22
import { createRoot } from 'react-dom/client'
3+
import { BrowserRouter, Routes, Route } from 'react-router-dom'
34
import './index.css'
45
import App from './App.tsx'
6+
import Solo from './Solo/index.tsx'
57

68
createRoot(document.getElementById('root')!).render(
79
<StrictMode>
8-
<App />
10+
<BrowserRouter>
11+
<Routes>
12+
{/* localhost:5173 */}
13+
<Route path="/" element={<App />} />
14+
{/* localhost:5173/solo */}
15+
<Route path="/solo" element={<Solo />} />
16+
</Routes>
17+
</BrowserRouter>
918
</StrictMode>,
1019
)

0 commit comments

Comments
 (0)