-
Notifications
You must be signed in to change notification settings - Fork 1
/
.eslintrc.js
76 lines (66 loc) · 1.81 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
module.exports = {
extends: [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:import/typescript",
"plugin:react/recommended",
"plugin:react-hooks/recommended",
"plugin:prettier/recommended",
],
parser: "@typescript-eslint/parser",
parserOptions: {
ecmaVersion: "latest",
ecmaFeatures: { jsx: true },
sourceType: "module",
warnOnUnsupportedTypeScriptVersion: true,
},
ignorePatterns: ["dist/", "node_modules/"],
plugins: ["simple-import-sort", "import"],
rules: {
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "warn",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/no-empty-function": "warn",
"@typescript-eslint/explicit-module-boundary-types": "warn",
"@typescript-eslint/no-use-before-define": "off",
"@typescript-eslint/no-var-requires": "off",
"no-console": [
"error",
{
allow: ["debug", "error"],
},
],
"react/prop-types": "off",
"react/require-default-props": "off",
"react/jsx-key": "warn",
"react/no-direct-mutation-state": "warn",
"react/react-in-jsx-scope": "off",
"sort-imports": "off",
"import/order": "off",
"import/first": "error",
"import/newline-after-import": "error",
"import/no-duplicates": "error",
"simple-import-sort/imports": "error",
"simple-import-sort/exports": "error",
"prettier/prettier": ["error", {
printWidth: 100,
tabWidth: 2,
useTabs: false,
semi: false,
singleQuote: false,
trailingComma: "all",
arrowParens: "avoid",
endOfLine: "lf",
plugins: [require("prettier-plugin-tailwindcss")],
}],
},
settings: {
react: {
version: "detect",
},
},
env: {
browser: true,
node: true,
},
}