Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature(#101): route 설정, Tailwind CSS 기본 설정, 스캐폴드 구성 #103

Merged
merged 3 commits into from
Nov 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions frontend/.eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ module.exports = {
plugins: ["react-refresh", "import-resolver-alias"],
rules: {
"react/jsx-filename-extension": ["warn", { extensions: [".tsx"] }],
"prettier/prettier": ["error", { endOfLine: "auto" }],
"react/react-in-jsx-scope": "off",
"react-refresh/only-export-components": ["warn", { allowConstantExport: true }]
}
Expand Down
2 changes: 1 addition & 1 deletion frontend/.prettierrc
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
"quoteProps": "as-needed",
"bracketSameLine": false,
"trailingComma": "none",
"endOfLine": "auto"
"endOfLine": "lf"
}
39 changes: 39 additions & 0 deletions frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"dependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-router-dom": "^6.18.0",
"recoil": "^0.7.7"
},
"devDependencies": {
Expand Down
42 changes: 0 additions & 42 deletions frontend/src/App.css

This file was deleted.

40 changes: 10 additions & 30 deletions frontend/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,35 +1,15 @@
import { useState } from 'react'
import reactLogo from './assets/react.svg'
import viteLogo from '/vite.svg'
import './App.css'
import { BrowserRouter, Routes, Route } from 'react-router-dom';
import Home from './Home';
import './global.css';

function App() {
const [count, setCount] = useState(0)

return (
<>
<div>
<a href="https://vitejs.dev" target="_blank">
<img src={viteLogo} className="logo" alt="Vite logo" />
</a>
<a href="https://react.dev" target="_blank">
<img src={reactLogo} className="logo react" alt="React logo" />
</a>
</div>
<h1>Vite + React</h1>
<div className="card">
<button onClick={() => setCount((count) => count + 1)}>
count is {count}
</button>
<p>
Edit <code>src/App.tsx</code> and save to test HMR
</p>
</div>
<p className="read-the-docs">
Click on the Vite and React logos to learn more
</p>
</>
)
<BrowserRouter>
<Routes>
<Route path="/" element={<Home />} />
</Routes>
</BrowserRouter>
);
}

export default App
export default App;
1 change: 1 addition & 0 deletions frontend/src/assets/1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
집에가고싶다.
1 change: 0 additions & 1 deletion frontend/src/assets/react.svg

This file was deleted.

9 changes: 9 additions & 0 deletions frontend/src/components/Header.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
function Home() {
return (
<div>
<h1 className="underline">Home</h1>
</div>
);
}

export default Home;
3 changes: 3 additions & 0 deletions frontend/src/global.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@tailwind base;
@tailwind components;
@tailwind utilities;
69 changes: 0 additions & 69 deletions frontend/src/index.css

This file was deleted.

9 changes: 4 additions & 5 deletions frontend/src/main.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import React from 'react'
import ReactDOM from 'react-dom/client'
import App from './App.tsx'
import './index.css'
import React from 'react';
import ReactDOM from 'react-dom/client';
import App from './App';

ReactDOM.createRoot(document.getElementById('root')!).render(
<React.StrictMode>
<App />
</React.StrictMode>,
)
);
9 changes: 9 additions & 0 deletions frontend/src/pages/Home/Home.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
function Home() {
return (
<div>
<h1 className="underline">Home</h1>
</div>
);
}

export default Home;
1 change: 1 addition & 0 deletions frontend/src/pages/Home/components/1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
집에가고싶다.
6 changes: 6 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.