Repository navigation
Expand file tree
/
Copy patheslint.config.js
More file actions
101 lines (100 loc) · 2.82 KB
/
Copy patheslint.config.js
File metadata and controls
101 lines (100 loc) · 2.82 KB
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
import js from '@eslint/js';
import tseslint from '@typescript-eslint/eslint-plugin';
import tsparser from '@typescript-eslint/parser';
import globals from 'globals';
export default [
js.configs.recommended,
{
files: ['**/*.ts', '**/*.tsx'],
languageOptions: {
parser: tsparser,
parserOptions: {
project: './tsconfig.json',
},
globals: {
...globals.browser,
...globals.node,
...globals.webextensions,
chrome: 'readonly',
window: 'readonly',
document: 'readonly',
navigator: 'readonly',
console: 'readonly',
localStorage: 'readonly',
sessionStorage: 'readonly',
crypto: 'readonly',
URL: 'readonly',
Blob: 'readonly',
FileReader: 'readonly',
MutationObserver: 'readonly',
ResizeObserver: 'readonly',
IntersectionObserver: 'readonly',
requestAnimationFrame: 'readonly',
cancelAnimationFrame: 'readonly',
setTimeout: 'readonly',
clearTimeout: 'readonly',
setInterval: 'readonly',
clearInterval: 'readonly',
queueMicrotask: 'readonly',
performance: 'readonly',
Element: 'readonly',
HTMLElement: 'readonly',
HTMLButtonElement: 'readonly',
HTMLInputElement: 'readonly',
HTMLTextAreaElement: 'readonly',
HTMLSelectElement: 'readonly',
Node: 'readonly',
ShadowRoot: 'readonly',
Event: 'readonly',
FocusEvent: 'readonly',
KeyboardEvent: 'readonly',
NodeFilter: 'readonly',
CSS: 'readonly',
getComputedStyle: 'readonly',
matchMedia: 'readonly',
btoa: 'readonly',
confirm: 'readonly',
prompt: 'readonly',
reportError: 'readonly',
__REACT_DEVTOOLS_GLOBAL_HOOK__: 'readonly',
MSApp: 'readonly',
global: 'readonly',
self: 'readonly',
process: 'readonly',
},
},
plugins: {
'@typescript-eslint': tseslint,
},
rules: {
...tseslint.configs.recommended.rules,
'no-unused-vars': 'off',
'no-empty': 'warn',
'no-prototype-builtins': 'off',
'no-constant-binary-expression': 'off',
'no-constant-condition': 'off',
'no-fallthrough': 'off',
'no-case-declarations': 'off',
'no-sparse-arrays': 'off',
'no-cond-assign': 'off',
'no-func-assign': 'off',
'no-control-regex': 'off',
'no-useless-escape': 'off',
'valid-typeof': 'off',
'getter-return': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': 'off',
},
ignores: [
'node_modules/**',
'.pnp/**',
'.pnp.js',
'dist/**',
'out/**',
'build/**',
'fastlane/**',
'log/**',
'public/**',
],
},
];