-
-
Notifications
You must be signed in to change notification settings - Fork 48
/
.eslintrc.js
58 lines (58 loc) · 2.19 KB
/
.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
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
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
plugins: ['@typescript-eslint', 'inclusive-language', 'prettier'],
extends: [
'airbnb',
'airbnb/hooks',
'eslint:recommended',
'react-app',
'plugin:@typescript-eslint/recommended',
'plugin:lodash-fp/recommended',
'plugin:import/errors',
'plugin:import/warnings',
'plugin:import/typescript',
'plugin:prettier/recommended',
],
ignorePatterns: [
'**/lib/**/*.*',
'**/dist/**/*.*',
'**/build/**/*.*',
'**/vendor/**/*.*',
'**/*.test.ts',
'**/*.config.js',
],
rules: {
'inclusive-language/use-inclusive-words': 'error',
// indent: ['error', 4, { ignoredNodes: ['JSXElement *', 'JSXElement'] }],
// 'react/jsx-indent': ['error', 4],
// 'react/jsx-indent-props': ['error', 4],
'max-len': [
'error',
{
code: 120,
tabWidth: 4,
ignoreComments: true,
ignoreStrings: true,
ignoreTemplateLiterals: true,
},
],
'import/prefer-default-export': 'off', // do not prefer default export
'import/no-extraneous-dependencies': 'off', // using monorepo
'no-underscore-dangle': 'off', // unigraph data model
'import/extensions': [
// targeting es module support so file extension is not needed
'off',
],
'react/jsx-filename-extension': ['error', { extensions: ['.tsx', '.jsx'] }],
'react/jsx-props-no-spreading': 'off',
'react/function-component-definition': 'off',
'react/prop-types': 'off', // for now, maybe we'll enforce this later
'no-param-reassign': 'warn', // also, for now
'import/no-unresolved': 'off', // temporarily disable unresolved check
'react/react-in-jsx-scope': 'off', // unnecessary for new jsx transpilation
'jsx-a11y/no-static-element-interactions': 'off', // disable for now
'jsx-a11y/click-events-have-key-events': 'off', // disable for now
'lodash-fp/use-fp': 'off', // regular lodash is used sometime
},
};