@rsdk/eslint-plugin 5.4.0-next.1 → 5.4.0-next.11
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/CHANGELOG.md +54 -0
- package/index.js +37 -3
- package/package.json +13 -13
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,52 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [5.4.0-next.11](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.10...v5.4.0-next.11) (2024-12-04)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
9
|
+
|
|
10
|
+
## [5.4.0-next.10](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.9...v5.4.0-next.10) (2024-12-03)
|
|
11
|
+
|
|
12
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
13
|
+
|
|
14
|
+
## [5.4.0-next.9](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.8...v5.4.0-next.9) (2024-12-02)
|
|
15
|
+
|
|
16
|
+
## [5.3.1-rc.1](https://github.com/R-Vision/rsdk/compare/v5.3.1-rc.0...v5.3.1-rc.1) (2024-11-28)
|
|
17
|
+
|
|
18
|
+
## [5.3.1-rc.0](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.6...v5.3.1-rc.0) (2024-11-28)
|
|
19
|
+
|
|
20
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
21
|
+
|
|
22
|
+
## [5.4.0-next.8](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.7...v5.4.0-next.8) (2024-11-28)
|
|
23
|
+
|
|
24
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
25
|
+
|
|
26
|
+
## [5.4.0-next.7](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.6...v5.4.0-next.7) (2024-11-28)
|
|
27
|
+
|
|
28
|
+
### Features
|
|
29
|
+
|
|
30
|
+
* eslint rule lines-around-comment ([65083bd](https://github.com/R-Vision/rsdk/commit/65083bd2e084344e08f2124e39afbbc23fdaa4f4))
|
|
31
|
+
|
|
32
|
+
## [5.4.0-next.6](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.5...v5.4.0-next.6) (2024-11-28)
|
|
33
|
+
|
|
34
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
35
|
+
|
|
36
|
+
## [5.4.0-next.5](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.4...v5.4.0-next.5) (2024-11-28)
|
|
37
|
+
|
|
38
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
39
|
+
|
|
40
|
+
## [5.4.0-next.4](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.3...v5.4.0-next.4) (2024-11-27)
|
|
41
|
+
|
|
42
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
43
|
+
|
|
44
|
+
## [5.4.0-next.3](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.2...v5.4.0-next.3) (2024-11-25)
|
|
45
|
+
|
|
46
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
47
|
+
|
|
48
|
+
## [5.4.0-next.2](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.1...v5.4.0-next.2) (2024-11-25)
|
|
49
|
+
|
|
50
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
51
|
+
|
|
6
52
|
## [5.4.0-next.1](https://github.com/R-Vision/rsdk/compare/v5.4.0-next.0...v5.4.0-next.1) (2024-11-08)
|
|
7
53
|
|
|
8
54
|
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
@@ -11,6 +57,14 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
11
57
|
|
|
12
58
|
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
13
59
|
|
|
60
|
+
## [5.3.1-rc.1](https://github.com/R-Vision/rsdk/compare/v5.3.1-rc.0...v5.3.1-rc.1) (2024-11-28)
|
|
61
|
+
|
|
62
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
63
|
+
|
|
64
|
+
## [5.3.1-rc.0](https://github.com/R-Vision/rsdk/compare/v5.3.0...v5.3.1-rc.0) (2024-11-28)
|
|
65
|
+
|
|
66
|
+
**Note:** Version bump only for package @rsdk/eslint-plugin
|
|
67
|
+
|
|
14
68
|
## [5.3.0](https://github.com/R-Vision/rsdk/compare/v5.3.0-next.4...v5.3.0) (2024-11-08)
|
|
15
69
|
|
|
16
70
|
**Note:** Version bump only for package @rsdk/eslint-plugin
|
package/index.js
CHANGED
|
@@ -14,10 +14,12 @@ module.exports = {
|
|
|
14
14
|
'simple-import-sort',
|
|
15
15
|
'import',
|
|
16
16
|
'unicorn',
|
|
17
|
+
'@stylistic/eslint-plugin',
|
|
17
18
|
],
|
|
18
19
|
extends: [
|
|
19
20
|
'plugin:@typescript-eslint/eslint-recommended',
|
|
20
|
-
|
|
21
|
+
|
|
22
|
+
// FIXME: не уверен что его стоит добавлять, но посмотреть в целом стоит
|
|
21
23
|
// 'plugin:@typescript-eslint/recommended-requiring-type-checking',
|
|
22
24
|
'plugin:@typescript-eslint/recommended',
|
|
23
25
|
'plugin:import/typescript',
|
|
@@ -71,8 +73,21 @@ module.exports = {
|
|
|
71
73
|
next: ['const', 'let', 'var', 'if'],
|
|
72
74
|
},
|
|
73
75
|
],
|
|
74
|
-
|
|
75
|
-
|
|
76
|
+
'@stylistic/lines-around-comment': [
|
|
77
|
+
'error',
|
|
78
|
+
{
|
|
79
|
+
beforeBlockComment: true,
|
|
80
|
+
beforeLineComment: true,
|
|
81
|
+
allowBlockStart: true,
|
|
82
|
+
allowObjectStart: true,
|
|
83
|
+
allowArrayStart: true,
|
|
84
|
+
allowClassStart: true,
|
|
85
|
+
allowEnumStart: true,
|
|
86
|
+
allowInterfaceStart: true,
|
|
87
|
+
allowModuleStart: true,
|
|
88
|
+
allowTypeStart: true,
|
|
89
|
+
}
|
|
90
|
+
],
|
|
76
91
|
'import/no-cycle': 'error',
|
|
77
92
|
'import/first': 'error',
|
|
78
93
|
'import/newline-after-import': 'error',
|
|
@@ -87,16 +102,22 @@ module.exports = {
|
|
|
87
102
|
[
|
|
88
103
|
'^(assert|buffer|child_process|cluster|console|constants|crypto|dgram|dns|domain|events|fs|http|https|module|net|os|path|punycode|querystring|readline|repl|stream|string_decoder|sys|timers|tls|tty|url|util|vm|zlib|freelist|v8|process|async_hooks|http2|perf_hooks)(/.*|$)',
|
|
89
104
|
],
|
|
105
|
+
|
|
90
106
|
// Packages. `react` related packages come first.
|
|
91
107
|
['^react', '^@?\\w'],
|
|
108
|
+
|
|
92
109
|
// Internal packages.
|
|
93
110
|
['^(@|@company|@ui|components|utils|config|vendored-lib)(/.*|$)'],
|
|
111
|
+
|
|
94
112
|
// Side effect imports.
|
|
95
113
|
['^\\u0000'],
|
|
114
|
+
|
|
96
115
|
// Parent imports. Put `..` last.
|
|
97
116
|
['^\\.\\.(?!/?$)', '^\\.\\./?$'],
|
|
117
|
+
|
|
98
118
|
// Other relative imports. Put same-folder imports and `.` last.
|
|
99
119
|
['^\\./(?=.*/)(?!/?$)', '^\\.(?!/?$)', '^\\./?$'],
|
|
120
|
+
|
|
100
121
|
// Style imports.
|
|
101
122
|
['^.+\\.s?css$'],
|
|
102
123
|
],
|
|
@@ -112,19 +133,25 @@ module.exports = {
|
|
|
112
133
|
|
|
113
134
|
// unicorn
|
|
114
135
|
'unicorn/custom-error-definition': 'off',
|
|
136
|
+
|
|
115
137
|
// Очень странная мотивация у этого правила, у меня может быть метод который подсчитывает количество товаров в заказе и собственно массив заказов
|
|
116
138
|
'unicorn/no-array-callback-reference': 'off',
|
|
139
|
+
|
|
117
140
|
// просто спорное правило
|
|
118
141
|
'unicorn/no-array-reduce': 'off',
|
|
119
142
|
'unicorn/no-keyword-prefix': 'off',
|
|
120
143
|
'no-negated-condition': 'off',
|
|
121
144
|
'no-nested-ternary': 'off',
|
|
145
|
+
|
|
122
146
|
// глупость, так как null хотя бы является валидным сериализуемым значением
|
|
123
147
|
'unicorn/no-null': 'off',
|
|
148
|
+
|
|
124
149
|
// Как правило, удобнее сгруппировать методы в namespace
|
|
125
150
|
'unicorn/no-static-only-class': 'off',
|
|
151
|
+
|
|
126
152
|
// дублирует правило @typescript-eslint/no-this-alias
|
|
127
153
|
'unicorn/no-this-assignment': 'off',
|
|
154
|
+
|
|
128
155
|
// портит regex например /\/?([\w\-_]+:[\w\-_]+)$/gi.exec(tag)?.[1]
|
|
129
156
|
'unicorn/better-regex': 'off',
|
|
130
157
|
'unicorn/no-unused-properties': 'off',
|
|
@@ -132,19 +159,26 @@ module.exports = {
|
|
|
132
159
|
'error',
|
|
133
160
|
{ varsIgnorePattern: '^_', argsIgnorePattern: '^_' },
|
|
134
161
|
],
|
|
162
|
+
|
|
135
163
|
// Пытался как-то консистентно эту историю организовать, но это около невозможно потому что порты например нет смысла делить
|
|
136
164
|
'unicorn/numeric-separators-style': 'off',
|
|
137
165
|
'unicorn/prefer-json-parse-buffer': 'error',
|
|
166
|
+
|
|
138
167
|
// пока мы не переехали на esm смысла нет
|
|
139
168
|
'unicorn/prefer-module': 'off',
|
|
169
|
+
|
|
140
170
|
// мешает делать typeguard `(var: MyInterface | undefined): var is MyInterface => Boolean(var)`
|
|
141
171
|
'unicorn/prefer-native-coercion-functions': 'off',
|
|
172
|
+
|
|
142
173
|
// иногда проще делать Array.from, а там где `spread` лучше, там и так понятно
|
|
143
174
|
'unicorn/prefer-spread': 'off',
|
|
175
|
+
|
|
144
176
|
// не нашёл гибкой конфигурации чтобы он не ругался на `param` например
|
|
145
177
|
'unicorn/prevent-abbreviations': 'off',
|
|
178
|
+
|
|
146
179
|
// мешает делать case: return some(a, b, c)
|
|
147
180
|
'unicorn/switch-case-braces': ['error', 'avoid'],
|
|
181
|
+
|
|
148
182
|
// некорректный парсинг, ругается на любой вызов метода find
|
|
149
183
|
'unicorn/no-array-method-this-argument': 'off',
|
|
150
184
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rsdk/eslint-plugin",
|
|
3
|
-
"version": "5.4.0-next.
|
|
3
|
+
"version": "5.4.0-next.11",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"publishConfig": {
|
|
@@ -8,18 +8,18 @@
|
|
|
8
8
|
},
|
|
9
9
|
"license": "Apache License 2.0",
|
|
10
10
|
"peerDependencies": {
|
|
11
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
12
|
-
"@typescript-eslint/parser": "^
|
|
13
|
-
"eslint": "^8.
|
|
14
|
-
"eslint-config-prettier": "^9.
|
|
11
|
+
"@typescript-eslint/eslint-plugin": "^7.18.0",
|
|
12
|
+
"@typescript-eslint/parser": "^7.18.0",
|
|
13
|
+
"eslint": "^8.57.0",
|
|
14
|
+
"eslint-config-prettier": "^9.1.0",
|
|
15
15
|
"eslint-formatter-codeframe": "^7.32.1",
|
|
16
|
-
"eslint-plugin-deprecation": "^
|
|
17
|
-
"eslint-plugin-import": "^2.
|
|
18
|
-
"eslint-plugin-prettier": "^5.
|
|
19
|
-
"eslint-plugin-simple-import-sort": "^
|
|
20
|
-
"eslint-plugin-unicorn": "^
|
|
21
|
-
"prettier": "^3.
|
|
22
|
-
"typescript": "
|
|
16
|
+
"eslint-plugin-deprecation": "^3.0.0",
|
|
17
|
+
"eslint-plugin-import": "^2.31.0",
|
|
18
|
+
"eslint-plugin-prettier": "^5.2.1",
|
|
19
|
+
"eslint-plugin-simple-import-sort": "^12.1.1",
|
|
20
|
+
"eslint-plugin-unicorn": "^56.0.1",
|
|
21
|
+
"prettier": "^3.4.1",
|
|
22
|
+
"typescript": "5.5.4"
|
|
23
23
|
},
|
|
24
|
-
"gitHead": "
|
|
24
|
+
"gitHead": "aeefd240acea47a74d5eb5568fdf88ba8df533ae"
|
|
25
25
|
}
|