forked from bbc/simorgh
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
31 lines (31 loc) · 884 Bytes
/
.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
module.exports = {
extends: [
'airbnb',
'plugin:prettier/recommended',
'plugin:jsx-a11y/recommended',
'plugin:cypress/recommended',
],
env: {
es6: true,
browser: true,
jest: true,
node: true,
},
parser: 'babel-eslint',
parserOptions: {
ecmaVersion: 2017,
sourceType: 'module',
ecmaFeatures: {
jsx: true,
},
},
plugins: ['prettier', 'json', 'jsx-a11y', 'react-hooks', 'cypress'],
rules: {
'react/forbid-foreign-prop-types': 'error',
'react/jsx-one-expression-per-line': 'off',
'linebreak-style': process.platform === 'win32' ? 'off' : ['error', 'unix'],
'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': 'warn',
'import/no-extraneous-dependencies': ['off', {'devDependencies': ['/.storybook/**', '**/stories.jsx', '/src/testHelpers/**', '/dataValidator/**']}],
},
};