-
Notifications
You must be signed in to change notification settings - Fork 3
/
.eslintrc.js
44 lines (43 loc) · 1.31 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
const config = {
rules: {
curly: 'error',
eqeqeq: 'error',
'eol-last': ['error', 'always'],
indent: ['error', 2, { SwitchCase: 1 }],
'linebreak-style': [ 'error', 'unix' ],
'new-cap': ['error', { 'properties': false }],
'no-unused-vars': ['error', { 'vars': 'all', 'args': 'after-used' }],
'no-use-before-define': 'error',
'no-trailing-spaces': 'error',
quotes: ['error', 'single'],
semi: ['error', 'always'],
'wrap-iife': ['error', 'outside'],
'brace-style': ['error', '1tbs', {'allowSingleLine': true }],
'block-spacing': ['error', 'always'],
'keyword-spacing': ['error', { 'before': true, 'after': true, 'overrides': {} }],
'space-before-blocks': 'error',
'space-before-function-paren': ['error', {
'anonymous': 'never',
'named': 'never',
'asyncArrow': 'always'
}],
'comma-spacing': ['error', { 'before': false, 'after': true }],
'comma-style': ['error', 'last'],
'no-lonely-if': 'error',
'func-call-spacing': 'error',
'space-infix-ops': 'error'
},
globals: {
'SDK_VERSION': 'readonly',
},
env: {
es6: true,
node: true,
jasmine: true, // needed for 'fail'
'jest/globals': true,
},
parser: '@babel/eslint-parser',
extends: 'eslint:recommended',
plugins: ['jest']
};
module.exports = config;