@perfective/eslint-config-react 0.7.0 → 0.8.0-alpha

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@perfective/eslint-config-react",
3
- "version": "0.7.0",
3
+ "version": "0.8.0-alpha",
4
4
  "description": "ESLint shareable rules configuration for React",
5
5
  "keywords": ["react", "code quality", "code standard", "code style", "eslint", "eslint-config", "lint", "perfective", "typescript"],
6
6
  "author": "Andrey Mikheychik <a.mikheychik@gmail.com>",
@@ -11,12 +11,12 @@
11
11
  },
12
12
  "license": "MIT",
13
13
  "dependencies": {
14
- "@perfective/eslint-config": "~0.17.0"
14
+ "@perfective/eslint-config": "~0.18.0-alpha"
15
15
  },
16
16
  "peerDependencies": {
17
17
  "eslint-plugin-jsx-a11y": "^6.5.1",
18
- "eslint-plugin-react": "^7.28.0",
19
- "eslint-plugin-react-hooks": "^4.3.0",
18
+ "eslint-plugin-react": "^7.29.4",
19
+ "eslint-plugin-react-hooks": "^4.4.0",
20
20
  "eslint-plugin-react-hooks-ssr": "^0.1.5",
21
21
  "eslint-plugin-react-perf": "^3.3.1"
22
22
  },
@@ -39,6 +39,8 @@ module.exports = {
39
39
  namedComponents: 'function-declaration',
40
40
  unnamedComponents: 'function-expression',
41
41
  }],
42
+ 'react/hook-use-state': 'error',
43
+ 'react/iframe-missing-sandbox': 'error',
42
44
  'react/no-access-state-in-setstate': 'error',
43
45
  'react/no-adjacent-inline-elements': 'error',
44
46
  'react/no-array-index-key': 'error',
@@ -11,6 +11,7 @@ module.exports = {
11
11
  'react/jsx-curly-brace-presence': ['warn', {
12
12
  props: 'never',
13
13
  children: 'always',
14
+ propElementValues: 'always',
14
15
  }],
15
16
  'react/jsx-curly-newline': ['warn', 'never'],
16
17
  'react/jsx-curly-spacing': ['warn', {
@@ -46,6 +47,7 @@ module.exports = {
46
47
  'react/jsx-key': ['error', {
47
48
  checkFragmentShorthand: true,
48
49
  checkKeyMustBeforeSpread: true,
50
+ warnDuplicates: true,
49
51
  }],
50
52
  'react/jsx-max-depth': ['error', {
51
53
  max: 4,
@@ -110,8 +112,10 @@ module.exports = {
110
112
  callbacksLast: true,
111
113
  shorthandFirst: true,
112
114
  shorthandLast: false,
115
+ multiline: 'ignore',
113
116
  noSortAlphabetically: false,
114
117
  reservedFirst: true,
118
+ locale: 'auto',
115
119
  }],
116
120
  'react/jsx-space-before-closing': 'off',
117
121
  'react/jsx-tag-spacing': ['warn', {