-
Notifications
You must be signed in to change notification settings - Fork 7
/
.eslintrc.js
53 lines (51 loc) · 1.43 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
module.exports = {
root: true,
env: {
node: true,
es6: true,
},
parser: '@typescript-eslint/parser',
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended'],
plugins: ['@typescript-eslint'],
rules: {
// Stuff to re-evaluate later
// '@typescript-eslint/require-ts-comment-description' : 'error',
'@typescript-eslint/no-var-requires': 'off',
'@typescript-eslint/no-unused-vars': 'off',
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'warn',
eqeqeq: 'error',
'no-invalid-this': 'error',
'no-return-assign': 'error',
'no-unused-expressions': [
'error',
{
allowTernary: true,
},
],
// 'no-unused-vars': [
// 'error', {
// 'args': 'after-used'
// }
// ],
curly: ['error', 'all'],
'no-useless-concat': 'error',
'no-useless-return': 'error',
'init-declarations': 'error',
'no-use-before-define': 'error',
'no-lonely-if': 'error',
'no-unneeded-ternary': 'error',
'no-whitespace-before-property': 'error',
'nonblock-statement-body-position': 'error',
'no-confusing-arrow': 'error',
'no-duplicate-imports': 'error',
'no-var': 'error',
'object-shorthand': 'error',
'prefer-const': 'error',
'prefer-template': 'error',
},
ignorePatterns: ['dist/'],
globals: {
Parse: true,
},
};