forked from HandCash/handcash-connect-sdk-js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
67 lines (67 loc) · 2.14 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
55
56
57
58
59
60
61
62
63
64
65
66
67
module.exports = {
'env': {
'node': true,
'es6': true,
'mocha': true,
},
'extends': [
'airbnb-base',
'airbnb-typescript/base',
'prettier'
],
'parser': '@typescript-eslint/parser',
'parserOptions': {
'project': './tsconfig.json',
'sourceType': 'module',
'ecmaVersion': 2020,
'allowImportExportEverywhere': false,
'codeFrame': true,
'ecmaFeatures': {
'jsx': true,
'modules': true,
'experimentalObjectRestSpread': true
}
},
'settings': {
'import/resolver': 'webpack',
},
'rules': {
'@typescript-eslint/lines-between-class-members': 'off',
'no-plusplus': ['error', { 'allowForLoopAfterthoughts': true }],
'quote-props': ['error', 'consistent'],
'no-return-assign': ['error', 'except-parens'],
'no-param-reassign': ['error', { 'props': false }],
'no-underscore-dangle': 'off',
'max-len': ['warn', { 'code': 120 }],
'indent': ['warn', 3],
'no-trailing-spaces': ['error', { 'skipBlankLines': true }],
},
'plugins': [
'mocha',
],
'overrides': [
{
'files': ['*.api-definition.js', '*.test.js'],
'rules': {
'import/no-extraneous-dependencies': ['error', { 'devDependencies': true }],
'no-unused-expressions': 'off',
'init-declarations': 'off',
'mocha/handle-done-callback': 'error',
'mocha/max-top-level-suites': 'error',
'mocha/no-exclusive-tests': 'error',
'mocha/no-global-tests': 'error',
'mocha/no-identical-title': 'error',
'mocha/no-nested-tests': 'error',
'mocha/no-return-and-callback': 'error',
'mocha/no-setup-in-describe': 'error',
'mocha/no-sibling-hooks': 'error',
'mocha/no-synchronous-tests': 'error',
'mocha/no-top-level-hooks': 'error',
'mocha/prefer-arrow-callback': 'error',
'mocha/valid-suite-description': 'error',
'mocha/no-async-describe': 'error',
'mocha/valid-test-description': 'error',
},
},
],
};