@voiceflow/eslint-config 7.13.0 → 7.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -4
- package/src/presets/common.js +1 -28
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voiceflow/eslint-config",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.15.0",
|
|
4
4
|
"exports": {
|
|
5
5
|
".": "./src/index.js",
|
|
6
6
|
"./node": "./src/node.js"
|
|
@@ -30,7 +30,6 @@
|
|
|
30
30
|
"eslint-plugin-jsdoc": "50.6.2",
|
|
31
31
|
"eslint-plugin-mdx": "3.1.5",
|
|
32
32
|
"eslint-plugin-no-secrets": "2.1.1",
|
|
33
|
-
"eslint-plugin-prefer-arrow": "1.2.3",
|
|
34
33
|
"eslint-plugin-prettier": "5.2.3",
|
|
35
34
|
"eslint-plugin-promise": "7.2.1",
|
|
36
35
|
"eslint-plugin-simple-import-sort": "12.1.1",
|
|
@@ -41,7 +40,7 @@
|
|
|
41
40
|
},
|
|
42
41
|
"devDependencies": {
|
|
43
42
|
"@voiceflow/dependency-cruiser-config": "1.8.9",
|
|
44
|
-
"@voiceflow/eslint-plugin": "1.
|
|
43
|
+
"@voiceflow/eslint-plugin": "1.3.0"
|
|
45
44
|
},
|
|
46
45
|
"peerDependencies": {
|
|
47
46
|
"@voiceflow/eslint-plugin": "^1"
|
|
@@ -52,5 +51,5 @@
|
|
|
52
51
|
"volta": {
|
|
53
52
|
"extends": "../../package.json"
|
|
54
53
|
},
|
|
55
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "200e1ee370c851867b580aea82f76c6a31c6cdc1"
|
|
56
55
|
}
|
package/src/presets/common.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
const sonarjs = require('eslint-plugin-sonarjs');
|
|
2
2
|
const promise = require('eslint-plugin-promise');
|
|
3
|
-
const preferArrow = require('eslint-plugin-prefer-arrow');
|
|
4
3
|
const noSecrets = require('eslint-plugin-no-secrets');
|
|
5
4
|
const comments = require('eslint-plugin-eslint-comments');
|
|
6
5
|
const youDontNeed = require('eslint-plugin-you-dont-need-lodash-underscore');
|
|
@@ -18,7 +17,6 @@ module.exports = [
|
|
|
18
17
|
unicorn,
|
|
19
18
|
'eslint-comments': comments,
|
|
20
19
|
'you-dont-need-lodash-underscore': youDontNeed,
|
|
21
|
-
'prefer-arrow': preferArrow,
|
|
22
20
|
'no-secrets': noSecrets,
|
|
23
21
|
},
|
|
24
22
|
},
|
|
@@ -61,7 +59,7 @@ module.exports = [
|
|
|
61
59
|
'no-process-exit': 'error',
|
|
62
60
|
'no-useless-call': 'error',
|
|
63
61
|
'quote-props': ['error', 'as-needed'],
|
|
64
|
-
'prefer-arrow-callback': 'error',
|
|
62
|
+
'prefer-arrow-callback': ['error', { allowNamedFunctions: true, allowUnboundThis: true }],
|
|
65
63
|
'lines-between-class-members': 'error',
|
|
66
64
|
'no-restricted-imports': [
|
|
67
65
|
'error',
|
|
@@ -71,35 +69,10 @@ module.exports = [
|
|
|
71
69
|
name: '@/main',
|
|
72
70
|
message: "Importing '@/main' directly is not allowed due to cyclic dependencies.",
|
|
73
71
|
},
|
|
74
|
-
{
|
|
75
|
-
name: 'nestjs-zod/z',
|
|
76
|
-
importNames: ['z'],
|
|
77
|
-
message: "Please import `z` directly from 'zod' instead.",
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
name: '@nestjs/common',
|
|
81
|
-
importNames: ['Body', 'Query', 'Param'],
|
|
82
|
-
message: "Please use `Body`, `Query` and `Param` from '@voiceflow/nestjs-common' instead.",
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
name: '@nestjs/swagger',
|
|
86
|
-
importNames: ['ApiBody', 'ApiQuery', 'ApiResponse'],
|
|
87
|
-
message:
|
|
88
|
-
"Please use `ZodApiBody`, `ZodApiQuery` and `ZodApiResponse` from '@voiceflow/nestjs-common' instead.",
|
|
89
|
-
},
|
|
90
72
|
],
|
|
91
73
|
},
|
|
92
74
|
],
|
|
93
75
|
|
|
94
|
-
'prefer-arrow/prefer-arrow-functions': [
|
|
95
|
-
'error',
|
|
96
|
-
{
|
|
97
|
-
disallowPrototype: false,
|
|
98
|
-
singleReturnOnly: true,
|
|
99
|
-
classPropertiesAllowed: false,
|
|
100
|
-
},
|
|
101
|
-
],
|
|
102
|
-
|
|
103
76
|
'eslint-comments/no-unused-disable': 'error',
|
|
104
77
|
'eslint-comments/disable-enable-pair': ['error', { allowWholeFile: true }],
|
|
105
78
|
|