generated from Team-INSERT/Repository-generator-Frontend
-
Notifications
You must be signed in to change notification settings - Fork 2
/
.eslintrc.js
60 lines (60 loc) · 1.67 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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
module.exports = {
root: true,
parser: "@typescript-eslint/parser",
plugins: ["@typescript-eslint", "prettier"],
parserOptions: {
project: "./tsconfig.json",
},
env: {
node: true,
},
extends: [
"next/core-web-vitals",
"plugin:@typescript-eslint/recommended",
"airbnb",
"airbnb-typescript",
"plugin:prettier/recommended",
],
rules: {
"import/extensions": [
"error",
"ignorePackages",
{
js: "never",
jsx: "never",
ts: "never",
tsx: "never",
},
],
// 'React' must be in scope when using JSX 에러 지우기(Next.js)
"react/react-in-jsx-scope": "off",
"react/jsx-no-useless-fragment": 0,
"react/button-has-type": 0,
// ts파일에서 tsx구문 허용(Next.js)
"@typescript-eslint/no-use-before-define": "off",
"react/jsx-filename-extension": [1, { extensions: [".ts", ".tsx"] }], // should add ".ts" if typescript project
"no-unused-vars": "off",
"no-param-reassign": "off",
"react/function-component-definition": [
2,
{ namedComponents: ["arrow-function", "function-declaration"] },
],
"@typescript-eslint/no-unused-vars": "warn",
"jsx-a11y/click-events-have-key-events": 0,
"jsx-a11y/no-static-element-interactions": 0,
"import/no-cycle": 0,
"react/require-default-props": 0,
"react/jsx-props-no-spreading": 0,
"no-empty-interface": 0,
"import/prefer-default-export": "off",
"jsx-a11y/label-has-associated-control": [
2,
{
labelAttributes: ["htmlFor"],
},
],
"react/no-array-index-key": 0,
"consistent-return": 0,
"react-hooks/exhaustive-deps": "off",
},
};