-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.eslintrc.js
More file actions
32 lines (32 loc) · 906 Bytes
/
.eslintrc.js
File metadata and controls
32 lines (32 loc) · 906 Bytes
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
31
32
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: ['react-app', 'prettier'],
overrides: [
{
env: {
node: true,
},
files: ['.eslintrc.{js,cjs}'],
parserOptions: {
sourceType: 'script',
},
},
],
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
},
rules: {
'import/no-unresolved': 'off', // import시 절대경로 오류 해결
'no-param-reassign': [
'error',
{ props: true, ignorePropertyModificationsFor: ['state'] },
], // 변수명 'state'의 배열 의존성 무시
'react/react-in-jsx-scope': 'off', // React를 import 하지 않아도 jsx 작성 가능
'react/jsx-filename-extension': [1, { extensions: ['.js', '.jsx'] }], // .js file 안에서도 jsx 작성 가능
'react/prop-types': 'off', // Type 선언을 하지 않아도 작성 가능
},
};