-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.eslintrc.js
30 lines (30 loc) · 1.04 KB
/
.eslintrc.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
module.exports = {
env: {
es6: true,
node: true,
jest: true,
},
extends: [
'eslint:recommended',
'plugin:react/recommended',
'plugin:@typescript-eslint/eslint-recommended', //eslint에서 권장하는 타입체크 플러그인들
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/recommended-requiring-type-checking',
],
parser: '@typescript-eslint/parser', //타입스트립트에서도 eslint를 사용하기 위해 설치한 파서
plugins: ['react', 'react-hooks', '@typescript-eslint'],
rules: {
indent: ['error', 2, { SwitchCase: 1 }], //들여쓰기 체크
semi: ['error', 'always'], //세미콜론 체크
quotes: ['error', 'double', { avoidEscape: true }], //따옴표 체크
'no-empty-function': 'off', //함수 띄어쓰기 체크인데 함수 실행()할때 에러낼 수 있으니 꺼버려
'@typescript-eslint/no-empty-function': 'off',
'react/display-name': 'off',
'react/prop-types': 'off',
},
settings: {
react: {
version: 'detect',
},
},
};