-
Notifications
You must be signed in to change notification settings - Fork 34
/
.eslintrc.json
133 lines (133 loc) · 3.72 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
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
{
"root": true,
"parser": "@babel/eslint-parser",
"parserOptions": {
"requireConfigFile": false,
"sourceType": "module",
"babelOptions": {
"presets": ["@babel/preset-env", "@babel/preset-react"],
"plugins": ["@babel/plugin-syntax-jsx"]
},
"ecmaFeatures": {
"jsx": true
}
},
"extends": [
"plugin:@wordpress/eslint-plugin/recommended",
"plugin:react/recommended",
"plugin:jsx-a11y/recommended",
"plugin:sonarjs/recommended-legacy",
"plugin:cypress/recommended",
"plugin:no-jquery/deprecated",
"plugin:compat/recommended"
],
"env": {
"browser": true,
"es6": true,
"node": true,
"mocha": true,
"cypress/globals": true
},
"globals": {
"wp": true,
"wpApiSettings": true,
"window": true,
"document": true
},
"plugins": ["react", "jsx-a11y", "sonarjs", "cypress", "no-jquery", "compat"],
"settings": {
"import/resolver": {
"webpack": {
"config": "webpack.config.js"
}
},
"react": {
"pragma": "wp"
}
},
"rules": {
"cypress/unsafe-to-chain-command": "off",
"cypress/no-assigning-return-values": "off",
"camelcase": ["error", { "properties": "never" }],
"lines-around-comment": "off",
"react/display-name": "off",
"react/jsx-curly-spacing": [
"error",
{
"when": "always",
"children": true
}
],
"react/jsx-equals-spacing": "error",
"react/jsx-indent": ["error", "tab"],
"react/jsx-indent-props": ["error", "tab"],
"react/jsx-key": "error",
"react/jsx-tag-spacing": "error",
"react/no-children-prop": "off",
"react/no-find-dom-node": "warn",
"react/prop-types": "off",
"vars-on-top": "warn",
"yoda": "off",
"linebreak-style": "off",
"prettier/prettier": "off",
"object-shorthand": "off",
"no-unused-vars": "off",
"no-console": "off",
"eqeqeq": "off",
"@wordpress/no-global-active-element": "off",
"no-alert": "off",
"no-undef": "off",
"jsdoc/no-undefined-types": "off",
"no-shadow": "off",
"sonarjs/no-duplicate-string": "off",
"sonarjs/prefer-single-boolean-return": "off",
"sonarjs/no-collapsible-if": "off",
"sonarjs/no-duplicated-branches": "off",
"sonarjs/no-nested-template-literals": "off",
"no-jquery/no-ready-shorthand": "off",
"no-jquery/no-ajax-events": "error",
"no-jquery/no-animate-toggle": "error",
"no-jquery/no-bind": "error",
"no-jquery/no-box-model": "error",
"no-jquery/no-browser": "error",
"no-jquery/no-camel-case": "error",
"no-jquery/no-constructor-attributes": "error",
"no-jquery/no-contains": "error",
"no-jquery/no-deferred": "error",
"no-jquery/no-delegate": "error",
"no-jquery/no-error": "error",
"no-jquery/no-escape-selector": "error",
"no-jquery/no-extend": "error",
"no-jquery/no-fx-interval": "error",
"no-jquery/no-global-eval": "error",
"no-jquery/no-has": "error",
"no-jquery/no-hold-ready": "error",
"no-jquery/no-is-array": "error",
"no-jquery/no-is-empty-object": "error",
"no-jquery/no-is-function": "error",
"no-jquery/no-is-numeric": "error",
"no-jquery/no-is-plain-object": "error",
"no-jquery/no-is-window": "error",
"no-jquery/no-load": "error",
"no-jquery/no-load-shorthand": "error",
"no-jquery/no-map": "error",
"no-jquery/no-map-collection": "error",
"no-jquery/no-map-util": "error",
"no-jquery/no-merge": "error",
"no-jquery/no-node-name": "error",
"no-jquery/no-noop": "error",
"no-jquery/no-now": "error",
"no-jquery/no-other-utils": "error",
"no-jquery/no-param": "error",
"no-jquery/no-parse-json": "error",
"no-jquery/no-parse-xml": "error",
"no-jquery/no-proxy": "error",
"no-jquery/no-selector-prop": "error",
"no-jquery/no-sizzle": "error",
"no-jquery/no-sub": "error",
"no-jquery/no-trim": "error",
"no-jquery/no-type": "error",
"no-jquery/no-unique": "error",
"no-jquery/no-when": "error"
}
}