-
Notifications
You must be signed in to change notification settings - Fork 3
/
.eslintrc.json
33 lines (31 loc) · 1.02 KB
/
.eslintrc.json
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
{
"extends": [
"@kontent-ai"
],
"overrides": [
{
"files": ["src/**/*.ts"],
"excludedFiles": ["src/log.ts"],
"rules": {
"no-restricted-syntax": [
"error",
{
"selector": "MemberExpression[object.name='console'][property.name=/^(log|warn|error|info|trace)$/]",
"message": "Don't log into the console directly. Use one of the functions from the log.ts file (logInfo, logWarning, logError) to ensure provided --logLevel is respected."
},
{
"selector": "CallExpression[callee.name='createManagementClient']",
"message": "Use the createClient function from src/utils/client.ts instead."
},
{
"selector": "NewExpression[callee.name='ManagementClient']",
"message": "Use the createClient function from src/utils/client.ts instead."
}
]
}
}
],
"parserOptions": {
"project": ["tsconfig.json", "tsconfig.tests.jsonc", "tsconfig.configs.jsonc"]
}
}