-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
54 lines (54 loc) · 1.42 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
module.exports = {
root: true,
extends: '@react-native-community',
parser: '@typescript-eslint/parser',
plugins: ['@typescript-eslint'],
rules: {
'prettier/prettier': ['error', { singleQuote: true, jsxSingleQuote: false, trailingComma: 'all' }],
'block-spacing': 2,
'brace-style': 2,
'comma-dangle': 0,
curly: ['error', 'multi-line'],
eqeqeq: ['error', 'always', { null: 'ignore' }],
'eol-last': 0,
indent: ['error', 'tab', { SwitchCase: 1 }],
'linebreak-style': ['error', 'unix'],
'max-len': [
'warn',
{
code: 120,
tabWidth: 4,
ignoreStrings: true,
},
],
'no-alert': 2,
'no-async-promise-executor': 2,
'no-console': 1,
'no-duplicate-case': 2,
'no-duplicate-imports': 2,
'no-else-return': ['error', { allowElseIf: false }],
'no-empty': ['error', { allowEmptyCatch: true }],
'no-empty-function': ['error', { allow: ['arrowFunctions'] }],
'no-extra-boolean-cast': 2,
'no-floating-decimal': 2,
'no-lonely-if': 2,
'no-mixed-spaces-and-tabs': 2,
'no-nested-ternary': 2,
'no-new-wrappers': 2,
'no-obj-calls': 2,
'no-plusplus': 2,
'no-shadow': 0,
'no-redeclare': 2,
'no-trailing-spaces': 2,
'no-unneeded-ternary': 2,
'no-useless-concat': 2,
'no-useless-return': 2,
'no-unused-vars': 2,
'no-var': 2,
'no-void': 2,
'prefer-template': 2,
semi: 0,
'spaced-comment': ['error', 'always', { exceptions: ['-'] }],
'jsx-quotes': ['error', 'prefer-double'],
},
};