Skip to content

Commit f3fe03f

Browse files
authored
✨ 프로젝트 추가 설정 (#4)
vitest, msw 환경 구축 yarn berry zero-install 설정 NodeJS 및 vitest, msw 버전 명시 Closes #PW-107
1 parent 6bd21f3 commit f3fe03f

18 files changed

+4488
-4922
lines changed

.editorconfig

-10
This file was deleted.

.eslintrc.cjs

+6
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1+
const vitest = require('eslint-plugin-vitest');
2+
13
module.exports = {
24
root: true,
35
env: { browser: true, es2020: true },
46
extends: [
57
'eslint:recommended',
68
'plugin:@typescript-eslint/recommended',
79
'plugin:react-hooks/recommended',
10+
'plugin:vitest/recommended',
811
'plugin:@tanstack/eslint-plugin-query/recommended',
912
],
1013
ignorePatterns: ['dist', '.eslintrc.cjs'],
@@ -16,4 +19,7 @@ module.exports = {
1619
{ allowConstantExport: true },
1720
],
1821
},
22+
globals: {
23+
...vitest.environments.env.globals,
24+
},
1925
};

.gitattributes

-4
This file was deleted.

.pnp.cjs

+2,413-2,939
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.vscode/extensions.json

-7
This file was deleted.

.yarn/install-state.gz

57.4 KB
Binary file not shown.

.yarnrc.yml

+2
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1+
nodeLinker: 'pnp'
2+
13
yarnPath: .yarn/releases/yarn-4.1.1.cjs

README.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@
7474
### 1️⃣ Language
7575
- TypeScript v5.3.3
7676
### 2️⃣ Framework & Library
77+
- Node v18.18.0
7778
- React v18.2.0
7879
- React Query v5.25.0
7980
- Axios v1.6.7
@@ -87,8 +88,10 @@
8788
- Amazon EC2
8889
### 6️⃣ Automation & Test Framework
8990
- GitHub Actions
90-
- Jest v29.7.0
91-
### 7️⃣ Collaboration & Project Management Tools
91+
- Vitest v1.4.0
92+
### 7️⃣ Mocking Library
93+
- MSW v2.2.13
94+
### 8️⃣ Collaboration & Project Management Tools
9295
- GitHub
9396
- Jira
9497
- Confluence

package.json

+16-4
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@
77
"dev": "vite",
88
"build": "tsc && vite build",
99
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
10-
"preview": "vite preview"
10+
"preview": "vite preview",
11+
"test": "vitest"
1112
},
1213
"dependencies": {
1314
"@tanstack/react-query": "^5.25.0",
@@ -20,20 +21,31 @@
2021
"devDependencies": {
2122
"@tanstack/eslint-plugin-query": "^5.28.11",
2223
"@tanstack/react-query-devtools": "^5.28.14",
24+
"@testing-library/jest-dom": "^6.4.2",
25+
"@testing-library/react": "^14.2.2",
26+
"@testing-library/user-event": "^14.5.2",
2327
"@types/node": "^20.12.4",
2428
"@types/react": "^18.2.56",
2529
"@types/react-dom": "^18.2.19",
30+
"@types/react-router-dom": "^5.3.3",
2631
"@typescript-eslint/eslint-plugin": "^7.0.2",
2732
"@typescript-eslint/parser": "^7.0.2",
2833
"@vitejs/plugin-react": "^4.2.1",
2934
"eslint": "^8.56.0",
3035
"eslint-config-prettier": "^9.1.0",
3136
"eslint-plugin-react-hooks": "^4.6.0",
3237
"eslint-plugin-react-refresh": "^0.4.5",
33-
"jest": "^29.7.0",
38+
"eslint-plugin-vitest": "^0.4.1",
39+
"jsdom": "^24.0.0",
3440
"msw": "^2.2.13",
3541
"prettier": "^3.2.5",
3642
"typescript": "5.3.3",
37-
"vite": "^5.1.4"
43+
"vite": "^5.1.4",
44+
"vitest": "^1.4.0"
45+
},
46+
"msw": {
47+
"workerDirectory": [
48+
"public"
49+
]
3850
}
39-
}
51+
}

0 commit comments

Comments
 (0)