From 75fe0596dadac3c284c9352cbafb35592c881e3a Mon Sep 17 00:00:00 2001 From: KimKyuHoi Date: Fri, 31 May 2024 02:38:18 +0900 Subject: [PATCH 1/3] =?UTF-8?q?docs:=20frontend=20=EB=A6=AC=EB=93=9C?= =?UTF-8?q?=EB=AF=B8=20=EC=9E=91=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/src/pages/group/components/HolidayDeleteModal.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/front/src/pages/group/components/HolidayDeleteModal.tsx b/front/src/pages/group/components/HolidayDeleteModal.tsx index f754e1a..1551926 100644 --- a/front/src/pages/group/components/HolidayDeleteModal.tsx +++ b/front/src/pages/group/components/HolidayDeleteModal.tsx @@ -78,7 +78,7 @@ const HolidayDeleteModal = ({ closeModal }: { closeModal: () => void }) => { /> {isError && ( 에러가 발생했습니다: {error?.message} From 6ef34b5391dea1a3f6b71e023ae5df93f0f822ee Mon Sep 17 00:00:00 2001 From: KimKyuHoi Date: Fri, 31 May 2024 02:39:56 +0900 Subject: [PATCH 2/3] =?UTF-8?q?docs:=20=EB=A6=AC=EB=93=9C=EB=AF=B8=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/README.md | 114 +++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 94 insertions(+), 20 deletions(-) diff --git a/front/README.md b/front/README.md index 0d6babe..b4f1eaa 100644 --- a/front/README.md +++ b/front/README.md @@ -1,30 +1,104 @@ -# React + TypeScript + Vite +# 1 Day 1 Baekjoon Frontend -This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules. +1 Day 1Baekjoon 프론트엔드 프로젝트 -Currently, two official plugins are available: +## 실행 방법 -- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh -- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh +이 프로젝트는 Vite + TypeScript + SWC로 이루어진 프로젝트입니다. -## Expanding the ESLint configuration +**pnpm이 없을 경우** -If you are developing a production application, we recommend updating the configuration to enable type aware lint rules: +``` +npm i -g pnpm +``` + +**프로젝트 시작할 때** + +``` +pnpm install +``` + +``` +pnpm run dev +``` + +- Port는 5173입니다. +- 배포된 서버에서 작업할 경우 .env파일을 만드셔서 작업하시면 될 것 같습니다. + - .env파일 생성할 경우 아래와 같이 둘 것. + ``` + VITE_BASE_URL="배포 서버" + ``` -- Configure the top-level `parserOptions` property like this: +**프로젝트내 라이브러리 및 script 명령어** -```js -export default { - // other rules... - parserOptions: { - ecmaVersion: 'latest', - sourceType: 'module', - project: ['./tsconfig.json', './tsconfig.node.json'], - tsconfigRootDir: __dirname, +- 라이브러리가 설치가 되지 않았다는 에러가 뜰 시 아래를 참고하여 설치하시면 + 됩니다. + +``` +{ + "name": "1day1baek", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", + "preview": "vite preview", + "format": "prettier --write .", + "test": "vitest" }, + "dependencies": { + "@emotion/react": "^11.11.4", + "@emotion/styled": "^11.11.5", + "@hookform/error-message": "^2.0.1", + "@hookform/resolvers": "^3.4.2", + "@tanstack/react-query": "^5.40.0", + "axios": "^1.7.2", + "dayjs": "^1.11.11", + "react": "^18.3.1", + "react-calendar": "^5.0.0", + "react-dom": "^18.3.1", + "react-hook-form": "^7.51.5", + "react-hot-toast": "^2.4.1", + "react-icons": "^5.2.1", + "react-router-dom": "^6.23.1", + "zod": "^3.23.8", + "zustand": "^4.5.2" + }, + "devDependencies": { + "@rushstack/eslint-config": "^3.7.0", + "@rushstack/eslint-patch": "^1.10.3", + "@tanstack/eslint-plugin-query": "^5.35.6", + "@tanstack/react-query-devtools": "^5.40.0", + "@testing-library/jest-dom": "^6.4.5", + "@testing-library/react": "^15.0.7", + "@trivago/prettier-plugin-sort-imports": "^4.3.0", + "@types/react": "^18.3.3", + "@types/react-dom": "^18.3.0", + "@typescript-eslint/eslint-plugin": "6.19.1", + "@typescript-eslint/parser": "^7.11.0", + "@vitejs/plugin-react": "^4.3.0", + "@vitejs/plugin-react-swc": "^3.7.0", + "eslint": "^8.57.0", + "eslint-config-prettier": "^9.1.0", + "eslint-plugin-jsx-a11y": "^6.8.0", + "eslint-plugin-no-relative-import-paths": "^1.5.4", + "eslint-plugin-prettier": "^5.1.3", + "eslint-plugin-react-hooks": "^4.6.2", + "eslint-plugin-react-refresh": "^0.4.7", + "jsdom": "^24.1.0", + "msw": "^2.3.0", + "prettier": "^3.2.5", + "typescript": "^5.4.5", + "vite": "^5.2.12", + "vitest": "^1.6.0" + }, + "msw": { + "workerDirectory": [ + "public" + ] + } } -``` -- Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked` -- Optionally add `plugin:@typescript-eslint/stylistic-type-checked` -- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list +``` From 2245cd63becb49da474cffc5533c345aa1bbea7a Mon Sep 17 00:00:00 2001 From: KimKyuHoi Date: Fri, 31 May 2024 02:44:08 +0900 Subject: [PATCH 3/3] =?UTF-8?q?docs:=20=EB=A6=AC=EB=93=9C=EB=AF=B8=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/front/README.md b/front/README.md index b4f1eaa..43824de 100644 --- a/front/README.md +++ b/front/README.md @@ -23,10 +23,11 @@ pnpm run dev ``` - Port는 5173입니다. -- 배포된 서버에서 작업할 경우 .env파일을 만드셔서 작업하시면 될 것 같습니다. +- 배포된 서버나 로컬에서 작업할 경우 파일 최상단에 .env파일을 만들어서 돌려야 + 됩니다. - .env파일 생성할 경우 아래와 같이 둘 것. ``` - VITE_BASE_URL="배포 서버" + VITE_BASE_URL="http://localhost:8080" ``` **프로젝트내 라이브러리 및 script 명령어**