-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Fix: 백엔드 .eslintrc.js 수정 jest 관련 룰을 설정할때 settings에 jest 버전을 명시해주는 설정이 필요했는데 이 부분이 누락되어서 수정했습니다. * Chore: yarn workspace 설정 현재 husky + lint-staged 패키지를 이용해 pre-commit hook 단계에서 formatting과 lint를 체크하는 동작이 제대로 동작하지 않는 문제가 있습니다. 직접적인 원인은 아닐 수 있는데 front와 server에서 모두 husky를 통해 pre-commit hook을 트리거하게 되는데 실제 commit은 통합적으로 이루어지니까 pre-commit hook 도 통합적으로 트리거하면 좋겠다는 생각이 들었습니다. 그래서 hook을 트리거 하는 설정은 root 디렉토리에서 가지고 있고 하위 디렉토리에서는 각각의 프로젝트에 맞는 핸들링을 설정해놓는 구조로 설정하면 좋을 것 같은데 이런 구조를 짜보려고 하니 yarn의 workspace 기능을 알게 되었고 적용해보았습니다. **yarn을 사용할 경우 얻을 수 있는 이점** 1. npm 을 이용하는 경우 스크립트나 패키지를 설치하거나 스크립트를 실행할 때 server/front 디렉토리로 이동 후 명령어를 실행해야 하는 불편함이 있는데, yarn의 workspace를 이용하면 루트 디렉토리 상에서도 명령어 실행이 가능해집니다. 2. server/front에서 모두 사용하는 패키지 같은 경우 루트의 node_modules 에서 통합적으로 관리하게 돼서 중복 설치가 줄어듭니다. **yarn을 사용할 경우 단점** 1. 모든 팀원들이 yarn을 설치하고 사용해야 합니다. 2. 명령어 실행시 매번 workspace를 지정해주어야 합니다. * Style: Init code format 그동안 eslint, prettier 설정이 제대로 동작하지 않아서 코드 포맷팅이 되지 않았던 코드의 포맷을 수정했습니다. * Fix: package.json 저장소 url 수정 fork한 개인 repository로 등록되어 있던 repository 링크를 수정하고 author 삭제 * Chore: settings.json 설정 추가 javascript.format.enable 설정 추가.
- Loading branch information
1 parent
dbc7ee0
commit c95be57
Showing
15 changed files
with
9,472 additions
and
11,378 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -102,3 +102,5 @@ dist | |
|
||
# TernJS port file | ||
.tern-port | ||
|
||
package-lock.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
dist | ||
scripts | ||
yarn.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
{ | ||
"presets": [ | ||
["@babel/preset-env",{ | ||
"targets" : ">0.25%, not dead", | ||
"useBuiltIns":"usage", | ||
"corejs": "3", | ||
"modules": "auto" | ||
}], | ||
"@babel/preset-react" | ||
] | ||
} | ||
"presets": [ | ||
[ | ||
"@babel/preset-env", | ||
{ | ||
"targets": ">0.25%, not dead", | ||
"useBuiltIns": "usage", | ||
"corejs": "3", | ||
"modules": "auto" | ||
} | ||
], | ||
"@babel/preset-react" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,8 @@ | ||
<!DOCTYPE html> | ||
|
||
<html> | ||
<head></head> | ||
<body> | ||
<div id ='root'> | ||
|
||
</div> | ||
</body> | ||
</html> | ||
<head></head> | ||
<body> | ||
<div id="root"></div> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
module.exports = { | ||
hooks: { | ||
'pre-commit': 'yarn precommit', | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"name": "issue-tracker-25", | ||
"version": "1.0.0", | ||
"private": true, | ||
"main": "index.js", | ||
"repository": "https://github.com/boostcamp-2020/IssueTracker-25.git", | ||
"license": "MIT", | ||
"workspaces": [ | ||
"front", | ||
"server" | ||
], | ||
"scripts": { | ||
"test": "run-s test:server test:front", | ||
"test:server": "yarn workspace server test", | ||
"test:front": "yarn workspace front test", | ||
"precommit:server": "yarn workspace server precommit", | ||
"precommit:front": "yarn workspace front precommit", | ||
"precommit": "run-p precommit:server precommit:front", | ||
"format": "prettier --write ." | ||
}, | ||
"devDependencies": { | ||
"husky": "^4.3.0", | ||
"npm-run-all": "^4.1.5", | ||
"prettier": "^2.1.2" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.