forked from Mikescops/git-notify-extension
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
116 lines (116 loc) · 3.93 KB
/
.eslintrc.json
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
{
"parserOptions": {
"parser": "@typescript-eslint/parser",
"ecmaVersion": 2019,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true
},
"lib": ["es2019", "dom"]
},
"globals": {
"browser": "writable"
},
"extends": [
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended", // Uses the recommended rules from the @typescript-eslint/eslint-plugin
"prettier", // Enables eslint-plugin-prettier and eslint-config-prettier. This will display prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array.
"plugin:compat/recommended" // Allow compat for browser functions
],
"plugins": ["@typescript-eslint", "react-hooks"],
"env": {
"browser": true,
"es6": true,
"node": true,
"webextensions": true
},
"rules": {
"brace-style": "error",
"block-scoped-var": "error",
"camelcase": "off",
"comma-style": ["error", "last"],
"comma-dangle": "error",
"curly": ["error", "all"],
"dot-notation": "error",
"eqeqeq": ["error", "allow-null"],
"eol-last": "error",
"guard-for-in": "error",
"indent": ["error", 4, { "SwitchCase": 1 }],
"keyword-spacing": "error",
"max-len": ["error", 120],
"new-cap": "off",
"no-bitwise": "error",
"no-caller": "error",
"no-cond-assign": ["error", "except-parens"],
"no-debugger": "error",
"no-empty": "error",
"no-eval": "error",
"no-extend-native": "error",
"no-irregular-whitespace": "error",
"no-iterator": "error",
"no-loop-func": "error",
"no-lonely-if": "error",
"no-mixed-spaces-and-tabs": "error",
"no-multiple-empty-lines": "error",
"no-multi-str": "error",
"no-new": "error",
"no-plusplus": [
"error",
{
"allowForLoopAfterthoughts": true
}
],
"no-proto": "error",
"no-sequences": "error",
"no-undef": "off",
"no-unused-vars": "error",
"no-with": "error",
"no-trailing-spaces": "error",
"one-var": ["error", "never"],
"quotes": ["error", "single"],
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"semi": ["error", "always"],
"space-in-parens": ["error", "never"],
"space-before-blocks": "error",
"space-before-function-paren": [
"error",
{
"anonymous": "always",
"named": "never"
}
],
"space-unary-ops": "error",
"spaced-comment": "error",
"valid-typeof": "error",
"wrap-iife": ["error", "inside"],
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-inferrable-types": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/no-unused-vars": [
"error",
{
"varsIgnorePattern": "[iI]gnored",
"argsIgnorePattern": "^_"
}
],
"@typescript-eslint/ban-types": [
"error",
{
"types": {
"Object": "Avoid using the `Object` type. Did you mean `object`?",
"Boolean": "Avoid using the `Boolean` type. Did you mean `boolean`?",
"Number": "Avoid using the `Number` type. Did you mean `number`?",
"String": "Avoid using the `String` type. Did you mean `string`?",
"Symbol": "Avoid using the `Symbol` type. Did you mean `symbol`?"
}
}
],
"@typescript-eslint/explicit-module-boundary-types": "off"
},
"settings": {
"react": {
"version": "^16.13.0"
}
}
}