-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
54 lines (54 loc) · 1.58 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 = {
extends: 'eslint:recommended',
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: '2017',
sourceType: 'module'
},
plugins: ['@typescript-eslint'],
env: {
browser: true,
commonjs: true,
node: true,
es6: true
},
rules: {
indent: ['error', 'tab', {
SwitchCase: 1,
MemberExpression: 1,
FunctionDeclaration: { parameters: 1 },
FunctionExpression: { parameters: 1 },
CallExpression: { arguments: 1 }
}],
'linebreak-style': ['error', 'unix'],
quotes: ['error', 'single'],
semi: ['error', 'always'],
'no-empty': 'off',
'no-unsued-vars': 'off',
'no-console': ['error', { allow: ['warn', 'error'] }],
'no-trailing-spaces': 'error',
'space-in-parens': 'error',
'space-before-function-paren': ['error', { anonymous: 'always', named: 'never', asyncArrow: 'always' }],
'space-before-blocks': 'error',
'arrow-spacing': 'error',
'keyword-spacing': 'error',
'comma-spacing': ['error', { before: false, after: true }],
'key-spacing': ['error', { beforeColon: false, afterColon: true, mode: 'minimum' }],
'object-curly-spacing': ['error', 'always'],
'object-curly-newline': ['error', { multiline: true }],
'max-len': ['error', {
code: 120,
ignoreUrls: true,
ignoreTemplateLiterals: true,
ignoreRegExpLiterals: true
}],
'@typescript-eslint/no-unused-vars': ['error', { args: 'none' }],
'@typescript-eslint/indent': ['error', 'tab', {
SwitchCase: 1,
MemberExpression: 1,
FunctionDeclaration: { parameters: 1 },
FunctionExpression: { parameters: 1 },
CallExpression: { arguments: 1 }
}]
}
};