-
Notifications
You must be signed in to change notification settings - Fork 57
/
.eslintrc.js
70 lines (70 loc) · 1.89 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
68
69
70
module.exports = {
env: { node: true, jest: true },
extends: ['@sap-cloud-sdk'],
parser: '@typescript-eslint/parser',
parserOptions: {
project: {
extends: 'tsconfig.json',
include: ['**/*.ts'],
exclude: [
'**/*.d.ts',
'**/dist/**/*',
'**/node_modules/**/*',
'test-packages/test-services*/**/*',
'test-packages/test-services-e2e/**/*',
'test-packages/memory-tests/sdk-v1/test-service/*',
'test-packages/memory-tests/sdk-canary/test-service/*',
'build-packages/check-pr/lib/**',
'build-packages/get-changelog/lib/**',
'packages/rest-generator/test/test-services/**/*',
'test-resources/cli/**/*',
'**/test-output/**',
'**/README.md'
]
},
sourceType: 'module'
},
ignorePatterns: [
'dist',
'node_modules',
'README.md',
'test-packages/test-services-odata-v2',
'test-packages/test-services-odata-v4',
'test-packages/test-services-odata-common',
'test-packages/test-services-openapi',
'test-packages/test-services-e2e',
'test-packages/memory-tests/sdk-v1/test-service',
'test-packages/memory-tests/sdk-canary/test-service',
'packages/rest-generator/test/test-services',
'scripts/',
'test-resources/cli/',
'test-resources/generator/test-output'
],
overrides: [
{
files: ['**/test/**/*'],
rules: {
'import/no-internal-modules': 'off',
'no-unused-expressions': 'off',
'jsdoc/require-jsdoc': 'off'
}
},
{
files: ['**/index.ts'],
rules: {
'jsdoc/require-description-complete-sentence': 'off'
}
}
],
rules: {
radix: 'off',
'no-restricted-syntax': [
'error',
{
selector: 'TSEnumDeclaration',
message:
'Enums are weird in TypeScript. Prefer union types or const objects instead.'
}
]
}
};