forked from ScratchAddons/ScratchAddons
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
69 lines (66 loc) · 1.52 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
{
"parserOptions": {
"sourceType": "module"
},
"env": {
"es2020": true,
"browser": true
},
"globals": {
// Scratch Addons-defined
"scratchAddons": "writable",
"__scratchAddonsTraps": "writable",
"__scratchAddonsRedux": "writable",
"_realConsole": "writable",
// Third Party-defined
"Vue": "readonly",
"IntlMessageFormat": "readonly",
"md5": "readonly",
"scratchblocks": "readonly",
"tinycolor": "readonly",
"Chart": "readonly",
// Scratch-defined
"Scratch": "readonly",
"Blockly": "readonly",
// Non-standard API
"Clipboard": "readonly",
"ClipboardItem": "readonly"
},
"extends": "eslint:recommended",
"rules": {
"no-prototype-builtins": 1,
"no-template-curly-in-string": 2,
"array-callback-return": 2,
"default-case-last": 2,
"eqeqeq": 2,
"guard-for-in": 2,
"no-empty": [2, { "allowEmptyCatch": true }],
"no-caller": 2,
"no-implied-eval": 2,
"no-new-wrappers": 2,
"no-proto": 2,
"no-warning-comments": 1,
"no-unused-vars": 0,
"no-useless-escape": 0,
"no-inner-declarations": 0,
"no-constant-condition": [2, { "checkLoops": false }]
},
"overrides": [
{
"files": [
"addon-api/background/*.js",
"addons/*/background.js",
"background/**/*.js",
"content-scripts/*.js",
"popups/**/*.js",
"webpages/**/*.js"
],
"env": {
"webextensions": true
},
"rules": {
"no-eval": 2
}
}
]
}