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

[넥스트레벨 Outwater] 페이먼츠 미션 STEP1 #10

Open
wants to merge 9 commits into
base: Outwater
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
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
27 changes: 27 additions & 0 deletions docs/TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,33 @@

## TODO

- 페이지

- [ ] List 페이지
- [ ] Add 페이지
- [ ] Alias 페이지

- 컴포넌트

- [ ] Card 컴포넌트
- [ ] CardForm 컴포넌트
- [ ] Modal 컴포넌트

- 그외
- [ ] 라우터 구현 (페이지 이동)

## 작업순서

- [ ] 기본 라우터 세팅(react-router-dom)
- [ ] 다음, 뒤로가기로 페이지 이동
- Add -> (modal) -> Alias -> List <-> Add
- [ ] Add 페이지
- [ ] Card 컴포넌트
- [ ] CadrForm 컴포넌트
- [ ] Modal 컴포넌트
- [ ] Alias 페이지
- [ ] List 페이지

## 요구사항 리스트

#### 카드 추가
Expand Down
29 changes: 26 additions & 3 deletions package-lock.json

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

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
"clean-webpack-plugin": "^4.0.0",
"html-webpack-plugin": "^5.5.0",
"react": "^17.0.2",
"react-dom": "^17.0.2"
"react-dom": "^17.0.2",
"react-router-dom": "^6.2.1"
},
"devDependencies": {
"@babel/core": "^7.16.7",
Expand Down
3 changes: 0 additions & 3 deletions src/App.css

This file was deleted.

17 changes: 15 additions & 2 deletions src/App.jsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,21 @@
import React from "react";
import "./App.css";
import AddPage from "./pages/Add";
import AliasPage from "./pages/Alias";
import ListPage from "./pages/List";

import { BrowserRouter, Routes, Route } from "react-router-dom";

const App = () => {
return <div className="test">init test</div>;
return (
<BrowserRouter>
<Routes>
<Route path="/" element={<AddPage />} />
<Route path="add" element={<AddPage />} />
Outwater marked this conversation as resolved.
Show resolved Hide resolved
<Route path="alias" element={<AliasPage />} />
<Route path="list" element={<ListPage />} />
</Routes>
</BrowserRouter>
);
};

export default App;
1 change: 1 addition & 0 deletions src/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React from "react";
import ReactDOM from "react-dom";

import App from "./App";

ReactDOM.render(<App />, document.getElementById("root"));
7 changes: 7 additions & 0 deletions src/pages/Add.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import React from "react";

const Add = () => {
return <div>AddPage</div>;
};

export default Add;
7 changes: 7 additions & 0 deletions src/pages/Alias.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import React from "react";

const Alias = () => {
return <div>AliasPage</div>;
};

export default Alias;
7 changes: 7 additions & 0 deletions src/pages/List.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import React from "react";

const List = () => {
return <div>ListPage</div>;
};

export default List;
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 2 additions & 0 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,12 @@ module.exports = {
port: 3000,
// devserver 에서만 핫로딩 가능하게
hot: true,
historyApiFallback: true,
},
output: {
filename: "bundle.js",
path: path.resolve(__dirname, "dist"),
publicPath: "/",
},
module: {
rules: [
Expand Down