-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.eslintrc.js
More file actions
67 lines (66 loc) · 1.95 KB
/
.eslintrc.js
File metadata and controls
67 lines (66 loc) · 1.95 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
module.exports = {
root: true,
extends: [
'plugin:@wordpress/eslint-plugin/recommended-with-formatting',
'plugin:jest/recommended',
'plugin:compat/recommended',
],
env: {
browser: true,
},
rules: {
semi: [ 'error', 'never' ],
'arrow-parens': [ 'error', 'as-needed' ],
camelcase: [ 'error', { allow: [ '\\w+(_\\d+)+' ] } ],
'object-curly-newline': [ 'error', {
ObjectExpression: {
multiline: true, minProperties: 3, consistent: true,
},
ObjectPattern: {
multiline: true, minProperties: 3, consistent: true,
},
ImportDeclaration: {
multiline: true, minProperties: 3, consistent: false,
},
ExportDeclaration: {
multiline: true, minProperties: 3, consistent: false,
},
} ],
'no-shadow': 'off',
'no-nested-ternary': 'off',
'no-mixed-spaces-and-tabs': [ 'error', 'smart-tabs' ],
'sort-vars': [ 'error', { ignoreCase: true } ],
'array-element-newline': [ 'error', 'consistent' ],
'@wordpress/valid-sprintf': 'off',
'@wordpress/no-unused-vars-before-return': 'off',
'jsdoc/no-undefined-types': 'off',
'@wordpress/no-unguarded-get-range-at': 'off',
'linebreak-style': [ 'error', 'unix' ],
'no-unused-expressions': 'off',
'import/no-extraneous-dependencies': 'off',
'import/no-unresolved': 'off',
'@wordpress/i18n-text-domain': 'off',
'@wordpress/i18n-translator-comments': 'off',
'@wordpress/no-base-control-with-label-without-id': 'off',
'no-unused-vars': [ 'error', { varsIgnorePattern: '^_' } ],
'react/jsx-indent': [ 2, 'tab', { indentLogicalExpressions: true } ],
'react/jsx-curly-brace-presence': [ 'error', { props: 'never', children: 'never' } ],
},
globals: {
localStorage: true,
fetch: true,
Waypoint: true,
shallow: true,
btoa: true,
alert: true,
Element: true,
FileReader: true,
MutationObserver: true,
IntersectionObserver: true,
InteractRunner: true,
interactions: true,
BUILD_TYPE: true,
PREMIUM_ACTIONS_NUM: true,
PREMIUM_INTERACTIONS_NUM: true,
},
}