-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
42 lines (41 loc) · 899 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
32
33
34
35
36
37
38
39
40
41
42
const { NODE_ENV } = process.env
const isLocal = NODE_ENV === undefined || NODE_ENV === 'local'
module.exports = {
env: {
node: true
},
extends: ['standard'],
plugins: ['@typescript-eslint'],
rules: {
'import/first': 2,
'import/newline-after-import': 2,
'no-alert': isLocal ? 0 : 2,
'no-console': isLocal ? 0 : 2,
'no-debugger': isLocal ? 0 : 2,
'no-empty-function': 2,
'no-multi-spaces': 2,
'no-new': 0,
'no-var': 2,
'object-shorthand': 2,
'padded-blocks': [2, 'never'],
'prefer-const': 2,
'space-before-function-paren': [
2,
{
anonymous: 'never',
named: 'never',
asyncArrow: 'always'
}
],
'@typescript-eslint/no-unused-vars': 2
},
overrides: [
{
files: ['demo/**/*'],
rules: {
'no-console': 0
}
}
],
parser: '@typescript-eslint/parser'
}