-
Notifications
You must be signed in to change notification settings - Fork 24
/
.eslintrc.js
88 lines (80 loc) · 2.1 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
77
78
79
80
81
82
83
84
85
86
87
88
/* eslint-disable quotes */
module.exports = {
"root": true,
"env": {
"browser": true,
"es6": true,
"greasemonkey": true,
"jquery": true,
// "node": true
},
"parserOptions": {
// "ecmaVersion": 12,
"ecmaVersion": "latest",
"sourceType": "script",
"ecmaFeatures": {
"globalReturn ": true,
"impliedStrict": true,
// "jsx": true,
},
},
// "extends": "eslint:all",
// "extends": "eslint:recommended",
"extends": [
"eslint:recommended",
// "eslint:all",
"plugin:css/recommended",
"plugin:jsonc/recommended-with-json",
// "plugin:no-jquery/recommended",
"plugin:no-jquery/deprecated",
// "plugin:no-jquery/slim",
// "plugin:no-jquery/all",
// "plugin:clean-regex/recommended"
"plugin:regexp/recommended",
// "plugin:regexp/all",
],
"plugins": [
"css",
"jsonc",
// "clean-regex",
"no-jquery",
"regexp",
],
"rules": {
"complexity": ["warn", 20],
"eqeqeq": "warn",
"func-style": "off",
// "indent": ["warn","tab" ],
// "indent": ["warn","tab", { "SwitchCase": 1 } ],
// "indent": ["warn","tab", { "ignoreComments": true, "SwitchCase": 1 } ],
"indent": ["warn","tab", { "ignoreComments": false, "SwitchCase": 1 } ],
"linebreak-style": ["warn","unix"],
"max-len": "off",
"max-statements-per-line": "off",
"new-cap": "off",
"no-alert": "warn",
"no-console": "warn",
"no-dupe-keys": "warn",
"no-extra-semi": "warn",
"no-inline-comments": "off",
"no-magic-numbers": "off",
"no-misleading-character-class": "warn",
"no-mixed-spaces-and-tabs": "warn",
// "no-var": "off",
"no-multiple-empty-lines": "off",
"no-tabs": "off",
"no-unused-labels": "warn",
"no-unused-vars": ["warn", {"vars": "all", "args": "after-used"}],
"no-useless-escape": "warn",
"padded-blocks": "off",
"quotes": ["warn", "single", { "allowTemplateLiterals": true }] ,
"require-jsdoc": "off",
"require-unicode-regexp": "off",
"semi": ["warn","always"],
// "strict": ["error", "global"],
"space-before-function-paren": "off",
// "space-in-parens": ["warn", "always"],
"unicode-bom": ["warn", "never"],
},
"reportUnusedDisableDirectives": true
};