|
1 | | -{ |
2 | | - "rules": { |
3 | | - "indent": [ |
| 1 | +module.exports = { |
| 2 | + rules: { |
| 3 | + indent: [ |
4 | 4 | 2, |
5 | | - 2, { |
6 | | - "SwitchCase": 1 |
7 | | - } |
8 | | - ], |
9 | | - "quotes": [ |
10 | | - 2, |
11 | | - "single", |
12 | | - "avoid-escape" |
13 | | - ], |
14 | | - "comma-dangle": [ |
15 | | - 2, |
16 | | - "always-multiline" |
17 | | - ], |
18 | | - "linebreak-style": [ |
19 | | - 2, |
20 | | - "unix" |
21 | | - ], |
22 | | - "semi": [ |
23 | | - 2, |
24 | | - "always" |
25 | | - ], |
26 | | - "space-before-function-paren": [ |
27 | | - 2, |
28 | | - "never", |
29 | | - ], |
30 | | - "space-return-throw-case": [ |
31 | | - 2 |
32 | | - ], |
33 | | - "array-bracket-spacing": [ |
34 | 5 | 2, |
35 | | - "never" |
36 | | - ], |
37 | | - "space-before-blocks": [ |
38 | | - 2 |
| 6 | + { |
| 7 | + SwitchCase: 1, |
| 8 | + }, |
39 | 9 | ], |
| 10 | + quotes: [2, 'single', 'avoid-escape'], |
| 11 | + 'comma-dangle': [2, 'always-multiline'], |
| 12 | + 'linebreak-style': [2, 'unix'], |
| 13 | + semi: [2, 'always'], |
| 14 | + 'space-before-function-paren': [2, 'never'], |
| 15 | + 'space-return-throw-case': [2], |
| 16 | + 'array-bracket-spacing': [2, 'never'], |
| 17 | + 'space-before-blocks': [2], |
40 | 18 |
|
41 | | - "jsx-quotes": [ |
| 19 | + 'jsx-quotes': [2, 'prefer-single'], |
| 20 | + 'key-spacing': [ |
42 | 21 | 2, |
43 | | - "prefer-single", |
44 | | - ], |
45 | | - "key-spacing": [ |
46 | | - 2, { |
47 | | - "beforeColon": false, |
48 | | - "afterColon": true |
| 22 | + { |
| 23 | + beforeColon: false, |
| 24 | + afterColon: true, |
49 | 25 | }, |
50 | 26 | ], |
51 | | - "comma-spacing": [ |
52 | | - 2, { |
53 | | - "before": false, |
54 | | - "after": true |
55 | | - } |
56 | | - ], |
57 | | - "space-after-keywords": [ |
| 27 | + 'comma-spacing': [ |
58 | 28 | 2, |
59 | | - "always", |
| 29 | + { |
| 30 | + before: false, |
| 31 | + after: true, |
| 32 | + }, |
60 | 33 | ], |
61 | | - "block-spacing": [ |
| 34 | + 'space-after-keywords': [2, 'always'], |
| 35 | + 'block-spacing': [2, 'always'], |
| 36 | + 'no-unused-vars': [ |
62 | 37 | 2, |
63 | | - "always" |
64 | | - ], |
65 | | - "no-unused-vars": [ |
66 | | - 2, { |
67 | | - "vars": "all", |
68 | | - "varsIgnorePattern": "React" |
69 | | - } |
70 | | - ], |
71 | | - "no-cond-assign": [ |
72 | | - 0 |
| 38 | + { |
| 39 | + vars: 'all', |
| 40 | + varsIgnorePattern: 'React', |
| 41 | + }, |
73 | 42 | ], |
74 | | - "eqeqeq": [2, "allow-null"], |
75 | | - "react/display-name": 1, |
76 | | - "react/forbid-prop-types": 1, |
77 | | - "react/jsx-boolean-value": [2, "always"], |
78 | | - "react/jsx-closing-bracket-location": 2, |
79 | | - "react/jsx-curly-spacing": 1, |
80 | | - "react/jsx-indent-props": [2, 2], |
81 | | - "react/jsx-max-props-per-line": 1, |
82 | | - "react/jsx-no-bind": 1, |
83 | | - "react/jsx-no-duplicate-props": 1, |
84 | | - "react/jsx-no-undef": 1, |
85 | | - "react/jsx-quotes": 1, |
86 | | - "react/jsx-uses-react": 1, |
87 | | - "react/jsx-uses-vars": 1, |
88 | | - "react/no-danger": 1, |
89 | | - "react/no-did-mount-set-state": 1, |
90 | | - "react/no-did-update-set-state": 1, |
91 | | - "react/no-direct-mutation-state": 1, |
92 | | - "react/no-multi-comp": 1, |
93 | | - "react/no-set-state": 1, |
94 | | - "react/no-unknown-property": 1, |
95 | | - "react/prefer-es6-class": 1, |
96 | | - "react/prop-types": 1, |
97 | | - "react/react-in-jsx-scope": 1, |
98 | | - "react/require-extension": 1, |
99 | | - "react/self-closing-comp": 1, |
100 | | - "react/sort-comp": 1, |
101 | | - "react/wrap-multilines": 1, |
| 43 | + 'no-cond-assign': [0], |
| 44 | + eqeqeq: [2, 'allow-null'], |
| 45 | + 'react/display-name': 1, |
| 46 | + 'react/forbid-prop-types': 1, |
| 47 | + 'react/jsx-boolean-value': [2, 'always'], |
| 48 | + 'react/jsx-closing-bracket-location': 2, |
| 49 | + 'react/jsx-curly-spacing': 1, |
| 50 | + 'react/jsx-indent-props': [2, 2], |
| 51 | + 'react/jsx-max-props-per-line': 1, |
| 52 | + 'react/jsx-no-bind': 1, |
| 53 | + 'react/jsx-no-duplicate-props': 1, |
| 54 | + 'react/jsx-no-undef': 1, |
| 55 | + 'react/jsx-quotes': 1, |
| 56 | + 'react/jsx-uses-react': 1, |
| 57 | + 'react/jsx-uses-vars': 1, |
| 58 | + 'react/no-danger': 1, |
| 59 | + 'react/no-did-mount-set-state': 1, |
| 60 | + 'react/no-did-update-set-state': 1, |
| 61 | + 'react/no-direct-mutation-state': 1, |
| 62 | + 'react/no-multi-comp': 1, |
| 63 | + 'react/no-set-state': 1, |
| 64 | + 'react/no-unknown-property': 1, |
| 65 | + 'react/prefer-es6-class': 1, |
| 66 | + 'react/prop-types': 1, |
| 67 | + 'react/react-in-jsx-scope': 1, |
| 68 | + 'react/require-extension': 1, |
| 69 | + 'react/self-closing-comp': 1, |
| 70 | + 'react/sort-comp': 1, |
| 71 | + 'react/wrap-multilines': 1, |
102 | 72 | }, |
103 | | - "env": { |
104 | | - "es6": true, |
105 | | - "browser": true, |
106 | | - "amd": true, |
| 73 | + env: { |
| 74 | + es6: true, |
| 75 | + browser: true, |
| 76 | + amd: true, |
107 | 77 | }, |
108 | | - "globals": { |
109 | | - "module": true, |
110 | | - "describe": true, |
111 | | - "beforeEach": true, |
112 | | - "afterEach": true, |
113 | | - "global": true, |
114 | | - "expect": true, |
115 | | - "it": true, |
| 78 | + globals: { |
| 79 | + module: true, |
| 80 | + describe: true, |
| 81 | + beforeEach: true, |
| 82 | + afterEach: true, |
| 83 | + global: true, |
| 84 | + expect: true, |
| 85 | + it: true, |
116 | 86 | }, |
117 | | - "extends": "eslint:recommended", |
118 | | - "ecmaFeatures": { |
119 | | - "jsx": true, |
120 | | - "modules": true, |
121 | | - "experimentalObjectRestSpread": true |
| 87 | + extends: 'eslint:recommended', |
| 88 | + ecmaFeatures: { |
| 89 | + jsx: true, |
| 90 | + modules: true, |
| 91 | + experimentalObjectRestSpread: true, |
122 | 92 | }, |
123 | | - "parser": "babel-eslint", |
124 | | - "plugins": [ |
125 | | - "react" |
126 | | - ] |
127 | | -} |
| 93 | + parser: 'babel-eslint', |
| 94 | + plugins: ['react'], |
| 95 | +}; |
0 commit comments