@petbee/eslint-config 1.0.1 → 1.0.2
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/rules/style.js +3 -8
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@petbee/eslint-config",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "Petbee's eslint config",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -42,8 +42,7 @@
|
|
|
42
42
|
"eslint-plugin-jest": "^27.6.0",
|
|
43
43
|
"eslint-plugin-node": "^11.1.0",
|
|
44
44
|
"eslint-plugin-prettier": "^5.0.1",
|
|
45
|
-
"eslint-plugin-react": "7.33.2"
|
|
46
|
-
"eslint-plugin-vtex": "^2.2.1"
|
|
45
|
+
"eslint-plugin-react": "7.33.2"
|
|
47
46
|
},
|
|
48
47
|
"peerDependencies": {
|
|
49
48
|
"eslint": "^8.0.0",
|
|
@@ -61,5 +60,5 @@
|
|
|
61
60
|
"publishConfig": {
|
|
62
61
|
"access": "public"
|
|
63
62
|
},
|
|
64
|
-
"gitHead": "
|
|
63
|
+
"gitHead": "3c90a0ee37ac4f15cafa2778c9e132bfbb4b6082"
|
|
65
64
|
}
|
package/rules/style.js
CHANGED
|
@@ -22,7 +22,6 @@ module.exports = {
|
|
|
22
22
|
|
|
23
23
|
// Enforce position of line comments
|
|
24
24
|
// https://eslint.org/docs/rules/line-comment-position
|
|
25
|
-
// TODO https://github.com/vtex/front-end-coding-standard/issues/30
|
|
26
25
|
'line-comment-position': [
|
|
27
26
|
'off',
|
|
28
27
|
{
|
|
@@ -33,7 +32,6 @@ module.exports = {
|
|
|
33
32
|
|
|
34
33
|
// Disallow comments inline after code
|
|
35
34
|
// https://eslint.org/docs/rules/no-inline-comments
|
|
36
|
-
// TODO https://github.com/vtex/front-end-coding-standard/issues/30
|
|
37
35
|
'no-inline-comments': 'off',
|
|
38
36
|
|
|
39
37
|
// Require or disallow newlines around directives
|
|
@@ -91,19 +89,17 @@ module.exports = {
|
|
|
91
89
|
'error',
|
|
92
90
|
{
|
|
93
91
|
selector: 'LabeledStatement',
|
|
94
|
-
message:
|
|
95
|
-
'Labels are a form of GOTO; using them makes code confusing and hard to maintain and understand.',
|
|
92
|
+
message: 'Labels are a form of GOTO; using them makes code confusing and hard to maintain and understand.',
|
|
96
93
|
},
|
|
97
94
|
{
|
|
98
95
|
selector: 'WithStatement',
|
|
99
|
-
message:
|
|
100
|
-
'`with` is disallowed in strict mode because it makes code impossible to predict and optimize.',
|
|
96
|
+
message: '`with` is disallowed in strict mode because it makes code impossible to predict and optimize.',
|
|
101
97
|
},
|
|
102
98
|
// ban all enums
|
|
103
99
|
{
|
|
104
100
|
selector: 'TSEnumDeclaration:not([const=true])',
|
|
105
101
|
message:
|
|
106
|
-
"Literal types and enums, in many cases, solve the same problem while enum has some trade-offs that usually literal types don't. Consider using a literal type instead.
|
|
102
|
+
"Literal types and enums, in many cases, solve the same problem while enum has some trade-offs that usually literal types don't. Consider using a literal type instead.",
|
|
107
103
|
},
|
|
108
104
|
],
|
|
109
105
|
|
|
@@ -183,7 +179,6 @@ module.exports = {
|
|
|
183
179
|
next: '*',
|
|
184
180
|
},
|
|
185
181
|
// import/order already handle padding lines between cjs-imports
|
|
186
|
-
// see https://github.com/vtex/typescript/issues/82
|
|
187
182
|
{
|
|
188
183
|
blankLine: 'any',
|
|
189
184
|
prev: ['cjs-import'],
|