@ls-stack/eslint-cfg 0.1.3 → 0.2.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/dist/main.d.ts +13 -1
- package/dist/main.js +83 -373
- package/dist/main.js.map +1 -1
- package/package.json +16 -15
package/dist/main.d.ts
CHANGED
|
@@ -9,10 +9,22 @@ declare const cfgFlags: {
|
|
|
9
9
|
ERROR_IN_CI_ONLY: 0 | 1 | 2;
|
|
10
10
|
IS_CI: boolean;
|
|
11
11
|
};
|
|
12
|
-
|
|
12
|
+
/**
|
|
13
|
+
* Plugins:
|
|
14
|
+
*
|
|
15
|
+
* Use @ls-stack/{rule} to change ls-stack rules.
|
|
16
|
+
* Use unicorn/{rule} to change unicorn rules.
|
|
17
|
+
*
|
|
18
|
+
* Env vars:
|
|
19
|
+
* CI: if true, will be more strict.
|
|
20
|
+
* EXPIRING_TODOS: if true, will not allow expiring todos.
|
|
21
|
+
*/
|
|
22
|
+
declare function lsStackEslintCfg({ extends: extendsConfig, rules, tsconfigRootDir, ignore, allowDefaultExport, }: {
|
|
13
23
|
extends?: ConfigWithExtends['extends'];
|
|
14
24
|
rules?: ConfigWithExtends['rules'];
|
|
15
25
|
tsconfigRootDir: string;
|
|
26
|
+
ignore?: string[];
|
|
27
|
+
allowDefaultExport?: string[];
|
|
16
28
|
}): TSESLint.FlatConfig.ConfigArray;
|
|
17
29
|
|
|
18
30
|
export { cfgFlags, lsStackEslintCfg };
|
package/dist/main.js
CHANGED
|
@@ -1,370 +1,5 @@
|
|
|
1
|
-
var __create = Object.create;
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
-
var __commonJS = (cb, mod) => function __require() {
|
|
8
|
-
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
19
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
20
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
21
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
22
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
23
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
24
|
-
mod
|
|
25
|
-
));
|
|
26
|
-
|
|
27
|
-
// node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/package.json
|
|
28
|
-
var require_package = __commonJS({
|
|
29
|
-
"node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/package.json"(exports, module) {
|
|
30
|
-
module.exports = {
|
|
31
|
-
name: "@eslint/js",
|
|
32
|
-
version: "9.16.0",
|
|
33
|
-
description: "ESLint JavaScript language implementation",
|
|
34
|
-
main: "./src/index.js",
|
|
35
|
-
types: "./types/index.d.ts",
|
|
36
|
-
scripts: {
|
|
37
|
-
"test:types": "tsc -p tests/types/tsconfig.json"
|
|
38
|
-
},
|
|
39
|
-
files: [
|
|
40
|
-
"LICENSE",
|
|
41
|
-
"README.md",
|
|
42
|
-
"src",
|
|
43
|
-
"types"
|
|
44
|
-
],
|
|
45
|
-
publishConfig: {
|
|
46
|
-
access: "public"
|
|
47
|
-
},
|
|
48
|
-
repository: {
|
|
49
|
-
type: "git",
|
|
50
|
-
url: "https://github.com/eslint/eslint.git",
|
|
51
|
-
directory: "packages/js"
|
|
52
|
-
},
|
|
53
|
-
homepage: "https://eslint.org",
|
|
54
|
-
bugs: "https://github.com/eslint/eslint/issues/",
|
|
55
|
-
keywords: [
|
|
56
|
-
"javascript",
|
|
57
|
-
"eslint-plugin",
|
|
58
|
-
"eslint"
|
|
59
|
-
],
|
|
60
|
-
license: "MIT",
|
|
61
|
-
engines: {
|
|
62
|
-
node: "^18.18.0 || ^20.9.0 || >=21.1.0"
|
|
63
|
-
}
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
});
|
|
67
|
-
|
|
68
|
-
// node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/configs/eslint-all.js
|
|
69
|
-
var require_eslint_all = __commonJS({
|
|
70
|
-
"node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/configs/eslint-all.js"(exports, module) {
|
|
71
|
-
"use strict";
|
|
72
|
-
module.exports = Object.freeze({
|
|
73
|
-
"rules": {
|
|
74
|
-
"accessor-pairs": "error",
|
|
75
|
-
"array-callback-return": "error",
|
|
76
|
-
"arrow-body-style": "error",
|
|
77
|
-
"block-scoped-var": "error",
|
|
78
|
-
"camelcase": "error",
|
|
79
|
-
"capitalized-comments": "error",
|
|
80
|
-
"class-methods-use-this": "error",
|
|
81
|
-
"complexity": "error",
|
|
82
|
-
"consistent-return": "error",
|
|
83
|
-
"consistent-this": "error",
|
|
84
|
-
"constructor-super": "error",
|
|
85
|
-
"curly": "error",
|
|
86
|
-
"default-case": "error",
|
|
87
|
-
"default-case-last": "error",
|
|
88
|
-
"default-param-last": "error",
|
|
89
|
-
"dot-notation": "error",
|
|
90
|
-
"eqeqeq": "error",
|
|
91
|
-
"for-direction": "error",
|
|
92
|
-
"func-name-matching": "error",
|
|
93
|
-
"func-names": "error",
|
|
94
|
-
"func-style": "error",
|
|
95
|
-
"getter-return": "error",
|
|
96
|
-
"grouped-accessor-pairs": "error",
|
|
97
|
-
"guard-for-in": "error",
|
|
98
|
-
"id-denylist": "error",
|
|
99
|
-
"id-length": "error",
|
|
100
|
-
"id-match": "error",
|
|
101
|
-
"init-declarations": "error",
|
|
102
|
-
"logical-assignment-operators": "error",
|
|
103
|
-
"max-classes-per-file": "error",
|
|
104
|
-
"max-depth": "error",
|
|
105
|
-
"max-lines": "error",
|
|
106
|
-
"max-lines-per-function": "error",
|
|
107
|
-
"max-nested-callbacks": "error",
|
|
108
|
-
"max-params": "error",
|
|
109
|
-
"max-statements": "error",
|
|
110
|
-
"new-cap": "error",
|
|
111
|
-
"no-alert": "error",
|
|
112
|
-
"no-array-constructor": "error",
|
|
113
|
-
"no-async-promise-executor": "error",
|
|
114
|
-
"no-await-in-loop": "error",
|
|
115
|
-
"no-bitwise": "error",
|
|
116
|
-
"no-caller": "error",
|
|
117
|
-
"no-case-declarations": "error",
|
|
118
|
-
"no-class-assign": "error",
|
|
119
|
-
"no-compare-neg-zero": "error",
|
|
120
|
-
"no-cond-assign": "error",
|
|
121
|
-
"no-console": "error",
|
|
122
|
-
"no-const-assign": "error",
|
|
123
|
-
"no-constant-binary-expression": "error",
|
|
124
|
-
"no-constant-condition": "error",
|
|
125
|
-
"no-constructor-return": "error",
|
|
126
|
-
"no-continue": "error",
|
|
127
|
-
"no-control-regex": "error",
|
|
128
|
-
"no-debugger": "error",
|
|
129
|
-
"no-delete-var": "error",
|
|
130
|
-
"no-div-regex": "error",
|
|
131
|
-
"no-dupe-args": "error",
|
|
132
|
-
"no-dupe-class-members": "error",
|
|
133
|
-
"no-dupe-else-if": "error",
|
|
134
|
-
"no-dupe-keys": "error",
|
|
135
|
-
"no-duplicate-case": "error",
|
|
136
|
-
"no-duplicate-imports": "error",
|
|
137
|
-
"no-else-return": "error",
|
|
138
|
-
"no-empty": "error",
|
|
139
|
-
"no-empty-character-class": "error",
|
|
140
|
-
"no-empty-function": "error",
|
|
141
|
-
"no-empty-pattern": "error",
|
|
142
|
-
"no-empty-static-block": "error",
|
|
143
|
-
"no-eq-null": "error",
|
|
144
|
-
"no-eval": "error",
|
|
145
|
-
"no-ex-assign": "error",
|
|
146
|
-
"no-extend-native": "error",
|
|
147
|
-
"no-extra-bind": "error",
|
|
148
|
-
"no-extra-boolean-cast": "error",
|
|
149
|
-
"no-extra-label": "error",
|
|
150
|
-
"no-fallthrough": "error",
|
|
151
|
-
"no-func-assign": "error",
|
|
152
|
-
"no-global-assign": "error",
|
|
153
|
-
"no-implicit-coercion": "error",
|
|
154
|
-
"no-implicit-globals": "error",
|
|
155
|
-
"no-implied-eval": "error",
|
|
156
|
-
"no-import-assign": "error",
|
|
157
|
-
"no-inline-comments": "error",
|
|
158
|
-
"no-inner-declarations": "error",
|
|
159
|
-
"no-invalid-regexp": "error",
|
|
160
|
-
"no-invalid-this": "error",
|
|
161
|
-
"no-irregular-whitespace": "error",
|
|
162
|
-
"no-iterator": "error",
|
|
163
|
-
"no-label-var": "error",
|
|
164
|
-
"no-labels": "error",
|
|
165
|
-
"no-lone-blocks": "error",
|
|
166
|
-
"no-lonely-if": "error",
|
|
167
|
-
"no-loop-func": "error",
|
|
168
|
-
"no-loss-of-precision": "error",
|
|
169
|
-
"no-magic-numbers": "error",
|
|
170
|
-
"no-misleading-character-class": "error",
|
|
171
|
-
"no-multi-assign": "error",
|
|
172
|
-
"no-multi-str": "error",
|
|
173
|
-
"no-negated-condition": "error",
|
|
174
|
-
"no-nested-ternary": "error",
|
|
175
|
-
"no-new": "error",
|
|
176
|
-
"no-new-func": "error",
|
|
177
|
-
"no-new-native-nonconstructor": "error",
|
|
178
|
-
"no-new-wrappers": "error",
|
|
179
|
-
"no-nonoctal-decimal-escape": "error",
|
|
180
|
-
"no-obj-calls": "error",
|
|
181
|
-
"no-object-constructor": "error",
|
|
182
|
-
"no-octal": "error",
|
|
183
|
-
"no-octal-escape": "error",
|
|
184
|
-
"no-param-reassign": "error",
|
|
185
|
-
"no-plusplus": "error",
|
|
186
|
-
"no-promise-executor-return": "error",
|
|
187
|
-
"no-proto": "error",
|
|
188
|
-
"no-prototype-builtins": "error",
|
|
189
|
-
"no-redeclare": "error",
|
|
190
|
-
"no-regex-spaces": "error",
|
|
191
|
-
"no-restricted-exports": "error",
|
|
192
|
-
"no-restricted-globals": "error",
|
|
193
|
-
"no-restricted-imports": "error",
|
|
194
|
-
"no-restricted-properties": "error",
|
|
195
|
-
"no-restricted-syntax": "error",
|
|
196
|
-
"no-return-assign": "error",
|
|
197
|
-
"no-script-url": "error",
|
|
198
|
-
"no-self-assign": "error",
|
|
199
|
-
"no-self-compare": "error",
|
|
200
|
-
"no-sequences": "error",
|
|
201
|
-
"no-setter-return": "error",
|
|
202
|
-
"no-shadow": "error",
|
|
203
|
-
"no-shadow-restricted-names": "error",
|
|
204
|
-
"no-sparse-arrays": "error",
|
|
205
|
-
"no-template-curly-in-string": "error",
|
|
206
|
-
"no-ternary": "error",
|
|
207
|
-
"no-this-before-super": "error",
|
|
208
|
-
"no-throw-literal": "error",
|
|
209
|
-
"no-undef": "error",
|
|
210
|
-
"no-undef-init": "error",
|
|
211
|
-
"no-undefined": "error",
|
|
212
|
-
"no-underscore-dangle": "error",
|
|
213
|
-
"no-unexpected-multiline": "error",
|
|
214
|
-
"no-unmodified-loop-condition": "error",
|
|
215
|
-
"no-unneeded-ternary": "error",
|
|
216
|
-
"no-unreachable": "error",
|
|
217
|
-
"no-unreachable-loop": "error",
|
|
218
|
-
"no-unsafe-finally": "error",
|
|
219
|
-
"no-unsafe-negation": "error",
|
|
220
|
-
"no-unsafe-optional-chaining": "error",
|
|
221
|
-
"no-unused-expressions": "error",
|
|
222
|
-
"no-unused-labels": "error",
|
|
223
|
-
"no-unused-private-class-members": "error",
|
|
224
|
-
"no-unused-vars": "error",
|
|
225
|
-
"no-use-before-define": "error",
|
|
226
|
-
"no-useless-assignment": "error",
|
|
227
|
-
"no-useless-backreference": "error",
|
|
228
|
-
"no-useless-call": "error",
|
|
229
|
-
"no-useless-catch": "error",
|
|
230
|
-
"no-useless-computed-key": "error",
|
|
231
|
-
"no-useless-concat": "error",
|
|
232
|
-
"no-useless-constructor": "error",
|
|
233
|
-
"no-useless-escape": "error",
|
|
234
|
-
"no-useless-rename": "error",
|
|
235
|
-
"no-useless-return": "error",
|
|
236
|
-
"no-var": "error",
|
|
237
|
-
"no-void": "error",
|
|
238
|
-
"no-warning-comments": "error",
|
|
239
|
-
"no-with": "error",
|
|
240
|
-
"object-shorthand": "error",
|
|
241
|
-
"one-var": "error",
|
|
242
|
-
"operator-assignment": "error",
|
|
243
|
-
"prefer-arrow-callback": "error",
|
|
244
|
-
"prefer-const": "error",
|
|
245
|
-
"prefer-destructuring": "error",
|
|
246
|
-
"prefer-exponentiation-operator": "error",
|
|
247
|
-
"prefer-named-capture-group": "error",
|
|
248
|
-
"prefer-numeric-literals": "error",
|
|
249
|
-
"prefer-object-has-own": "error",
|
|
250
|
-
"prefer-object-spread": "error",
|
|
251
|
-
"prefer-promise-reject-errors": "error",
|
|
252
|
-
"prefer-regex-literals": "error",
|
|
253
|
-
"prefer-rest-params": "error",
|
|
254
|
-
"prefer-spread": "error",
|
|
255
|
-
"prefer-template": "error",
|
|
256
|
-
"radix": "error",
|
|
257
|
-
"require-atomic-updates": "error",
|
|
258
|
-
"require-await": "error",
|
|
259
|
-
"require-unicode-regexp": "error",
|
|
260
|
-
"require-yield": "error",
|
|
261
|
-
"sort-imports": "error",
|
|
262
|
-
"sort-keys": "error",
|
|
263
|
-
"sort-vars": "error",
|
|
264
|
-
"strict": "error",
|
|
265
|
-
"symbol-description": "error",
|
|
266
|
-
"unicode-bom": "error",
|
|
267
|
-
"use-isnan": "error",
|
|
268
|
-
"valid-typeof": "error",
|
|
269
|
-
"vars-on-top": "error",
|
|
270
|
-
"yoda": "error"
|
|
271
|
-
}
|
|
272
|
-
});
|
|
273
|
-
}
|
|
274
|
-
});
|
|
275
|
-
|
|
276
|
-
// node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/configs/eslint-recommended.js
|
|
277
|
-
var require_eslint_recommended = __commonJS({
|
|
278
|
-
"node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/configs/eslint-recommended.js"(exports, module) {
|
|
279
|
-
"use strict";
|
|
280
|
-
module.exports = Object.freeze({
|
|
281
|
-
rules: Object.freeze({
|
|
282
|
-
"constructor-super": "error",
|
|
283
|
-
"for-direction": "error",
|
|
284
|
-
"getter-return": "error",
|
|
285
|
-
"no-async-promise-executor": "error",
|
|
286
|
-
"no-case-declarations": "error",
|
|
287
|
-
"no-class-assign": "error",
|
|
288
|
-
"no-compare-neg-zero": "error",
|
|
289
|
-
"no-cond-assign": "error",
|
|
290
|
-
"no-const-assign": "error",
|
|
291
|
-
"no-constant-binary-expression": "error",
|
|
292
|
-
"no-constant-condition": "error",
|
|
293
|
-
"no-control-regex": "error",
|
|
294
|
-
"no-debugger": "error",
|
|
295
|
-
"no-delete-var": "error",
|
|
296
|
-
"no-dupe-args": "error",
|
|
297
|
-
"no-dupe-class-members": "error",
|
|
298
|
-
"no-dupe-else-if": "error",
|
|
299
|
-
"no-dupe-keys": "error",
|
|
300
|
-
"no-duplicate-case": "error",
|
|
301
|
-
"no-empty": "error",
|
|
302
|
-
"no-empty-character-class": "error",
|
|
303
|
-
"no-empty-pattern": "error",
|
|
304
|
-
"no-empty-static-block": "error",
|
|
305
|
-
"no-ex-assign": "error",
|
|
306
|
-
"no-extra-boolean-cast": "error",
|
|
307
|
-
"no-fallthrough": "error",
|
|
308
|
-
"no-func-assign": "error",
|
|
309
|
-
"no-global-assign": "error",
|
|
310
|
-
"no-import-assign": "error",
|
|
311
|
-
"no-invalid-regexp": "error",
|
|
312
|
-
"no-irregular-whitespace": "error",
|
|
313
|
-
"no-loss-of-precision": "error",
|
|
314
|
-
"no-misleading-character-class": "error",
|
|
315
|
-
"no-new-native-nonconstructor": "error",
|
|
316
|
-
"no-nonoctal-decimal-escape": "error",
|
|
317
|
-
"no-obj-calls": "error",
|
|
318
|
-
"no-octal": "error",
|
|
319
|
-
"no-prototype-builtins": "error",
|
|
320
|
-
"no-redeclare": "error",
|
|
321
|
-
"no-regex-spaces": "error",
|
|
322
|
-
"no-self-assign": "error",
|
|
323
|
-
"no-setter-return": "error",
|
|
324
|
-
"no-shadow-restricted-names": "error",
|
|
325
|
-
"no-sparse-arrays": "error",
|
|
326
|
-
"no-this-before-super": "error",
|
|
327
|
-
"no-undef": "error",
|
|
328
|
-
"no-unexpected-multiline": "error",
|
|
329
|
-
"no-unreachable": "error",
|
|
330
|
-
"no-unsafe-finally": "error",
|
|
331
|
-
"no-unsafe-negation": "error",
|
|
332
|
-
"no-unsafe-optional-chaining": "error",
|
|
333
|
-
"no-unused-labels": "error",
|
|
334
|
-
"no-unused-private-class-members": "error",
|
|
335
|
-
"no-unused-vars": "error",
|
|
336
|
-
"no-useless-backreference": "error",
|
|
337
|
-
"no-useless-catch": "error",
|
|
338
|
-
"no-useless-escape": "error",
|
|
339
|
-
"no-with": "error",
|
|
340
|
-
"require-yield": "error",
|
|
341
|
-
"use-isnan": "error",
|
|
342
|
-
"valid-typeof": "error"
|
|
343
|
-
})
|
|
344
|
-
});
|
|
345
|
-
}
|
|
346
|
-
});
|
|
347
|
-
|
|
348
|
-
// node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/index.js
|
|
349
|
-
var require_src = __commonJS({
|
|
350
|
-
"node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/index.js"(exports, module) {
|
|
351
|
-
"use strict";
|
|
352
|
-
var { version } = require_package();
|
|
353
|
-
module.exports = {
|
|
354
|
-
meta: {
|
|
355
|
-
name: "@eslint/js",
|
|
356
|
-
version
|
|
357
|
-
},
|
|
358
|
-
configs: {
|
|
359
|
-
all: require_eslint_all(),
|
|
360
|
-
recommended: require_eslint_recommended()
|
|
361
|
-
}
|
|
362
|
-
};
|
|
363
|
-
}
|
|
364
|
-
});
|
|
365
|
-
|
|
366
1
|
// src/main.ts
|
|
367
|
-
|
|
2
|
+
import eslint from "@eslint/js";
|
|
368
3
|
import { extendedLintPlugin } from "@ls-stack/extended-lint";
|
|
369
4
|
import eslintUnicornPlugin from "eslint-plugin-unicorn";
|
|
370
5
|
import vitest from "eslint-plugin-vitest";
|
|
@@ -375,6 +10,7 @@ var WARN = 1;
|
|
|
375
10
|
var ERROR = 2;
|
|
376
11
|
var ERROR_IN_CI = isCI ? ERROR : WARN;
|
|
377
12
|
var ERROR_IN_CI_ONLY = isCI ? ERROR : 0;
|
|
13
|
+
var errorOnExpiringTodos = process.env.EXPIRING_TODOS === "true" || !isCI;
|
|
378
14
|
var cfgFlags = {
|
|
379
15
|
OFF,
|
|
380
16
|
WARN,
|
|
@@ -386,10 +22,12 @@ var cfgFlags = {
|
|
|
386
22
|
function lsStackEslintCfg({
|
|
387
23
|
extends: extendsConfig = [],
|
|
388
24
|
rules,
|
|
389
|
-
tsconfigRootDir
|
|
25
|
+
tsconfigRootDir,
|
|
26
|
+
ignore = [],
|
|
27
|
+
allowDefaultExport = ["eslint.config.{js,cjs,mjs,ts}"]
|
|
390
28
|
}) {
|
|
391
29
|
return tseslint.config(
|
|
392
|
-
|
|
30
|
+
eslint.configs.recommended,
|
|
393
31
|
...tseslint.configs.recommendedTypeChecked,
|
|
394
32
|
{
|
|
395
33
|
linterOptions: {
|
|
@@ -405,7 +43,7 @@ function lsStackEslintCfg({
|
|
|
405
43
|
},
|
|
406
44
|
{
|
|
407
45
|
plugins: {
|
|
408
|
-
"@
|
|
46
|
+
"@ls-stack": extendedLintPlugin,
|
|
409
47
|
unicorn: eslintUnicornPlugin,
|
|
410
48
|
vitest
|
|
411
49
|
},
|
|
@@ -449,6 +87,13 @@ function lsStackEslintCfg({
|
|
|
449
87
|
],
|
|
450
88
|
/* typescript */
|
|
451
89
|
"@typescript-eslint/no-unnecessary-condition": ERROR_IN_CI,
|
|
90
|
+
"@typescript-eslint/no-non-null-assertion": ERROR_IN_CI,
|
|
91
|
+
"@typescript-eslint/consistent-type-assertions": [
|
|
92
|
+
ERROR,
|
|
93
|
+
{
|
|
94
|
+
assertionStyle: "never"
|
|
95
|
+
}
|
|
96
|
+
],
|
|
452
97
|
"@typescript-eslint/naming-convention": [
|
|
453
98
|
"error",
|
|
454
99
|
{
|
|
@@ -461,17 +106,73 @@ function lsStackEslintCfg({
|
|
|
461
106
|
"@typescript-eslint/no-unused-vars": [
|
|
462
107
|
ERROR_IN_CI,
|
|
463
108
|
{
|
|
464
|
-
argsIgnorePattern: "_
|
|
109
|
+
argsIgnorePattern: "_$",
|
|
465
110
|
ignoreRestSiblings: true,
|
|
466
|
-
varsIgnorePattern: "_
|
|
111
|
+
varsIgnorePattern: "_$"
|
|
467
112
|
}
|
|
468
113
|
],
|
|
469
114
|
"@typescript-eslint/no-shadow": [
|
|
470
115
|
ERROR_IN_CI,
|
|
471
116
|
{ ignoreOnInitialization: true, allow: ["expect"] }
|
|
472
117
|
],
|
|
118
|
+
"@typescript-eslint/no-unsafe-assignment": OFF,
|
|
119
|
+
"unicorn/expiring-todo-comments": [
|
|
120
|
+
ERROR_IN_CI,
|
|
121
|
+
{
|
|
122
|
+
terms: [
|
|
123
|
+
"FIX",
|
|
124
|
+
// 'TODO',
|
|
125
|
+
"palinter-ignore-unused-next-line",
|
|
126
|
+
"palinter-ignore-not-have-direct-circular-deps",
|
|
127
|
+
"palinter-ignore-not-have-circular-deps",
|
|
128
|
+
"palinter-ignore-not-have-unused-exports"
|
|
129
|
+
],
|
|
130
|
+
ignore: [/^ HACK:/],
|
|
131
|
+
allowWarningComments: false,
|
|
132
|
+
...!errorOnExpiringTodos && { date: "2000-01-01" }
|
|
133
|
+
}
|
|
134
|
+
],
|
|
135
|
+
"unicorn/require-array-join-separator": ERROR_IN_CI,
|
|
136
|
+
"unicorn/no-empty-file": ERROR_IN_CI,
|
|
137
|
+
"unicorn/no-array-reduce": [
|
|
138
|
+
ERROR_IN_CI,
|
|
139
|
+
{ allowSimpleOperations: true }
|
|
140
|
+
],
|
|
141
|
+
"unicorn/no-array-for-each": ERROR_IN_CI,
|
|
473
142
|
/* extended-lint */
|
|
474
|
-
"@
|
|
143
|
+
"@ls-stack/no-unused-type-props-in-args": ERROR,
|
|
144
|
+
"@ls-stack/improved-no-unnecessary-condition": ERROR,
|
|
145
|
+
"@ls-stack/no-optional-root-props": ERROR_IN_CI,
|
|
146
|
+
"@ls-stack/prefer-single-line-if": [
|
|
147
|
+
WARN,
|
|
148
|
+
{ maxLineLength: 80, maxNonSimpleConditionLength: 40 }
|
|
149
|
+
],
|
|
150
|
+
"@ls-stack/prefer-named-functions": [WARN, { ignoreRegex: "Fn$" }],
|
|
151
|
+
"@ls-stack/require-description": [ERROR, { ignore: ["eslint"] }],
|
|
152
|
+
"@ls-stack/no-default-export": ERROR,
|
|
153
|
+
"@ls-stack/no-unnecessary-casting": [
|
|
154
|
+
ERROR_IN_CI,
|
|
155
|
+
{
|
|
156
|
+
additionalCastFunctions: [
|
|
157
|
+
{ name: "castToString", expectedType: "string" },
|
|
158
|
+
{ name: "castToNumber", expectedType: "number" }
|
|
159
|
+
]
|
|
160
|
+
}
|
|
161
|
+
],
|
|
162
|
+
"@ls-stack/no-type-guards": [
|
|
163
|
+
ERROR,
|
|
164
|
+
{
|
|
165
|
+
alternativeMsgs: {
|
|
166
|
+
inArrayFilter: "Use filterWithNarrowing instead",
|
|
167
|
+
inArrayFind: "Use findWithNarrowing instead"
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
],
|
|
171
|
+
"@ls-stack/use-top-level-regex": ERROR,
|
|
172
|
+
"@ls-stack/use-types-directly-above-usage": [ERROR],
|
|
173
|
+
/* vitest */
|
|
174
|
+
"vitest/expect-expect": ERROR_IN_CI,
|
|
175
|
+
"vitest/no-identical-title": ERROR_IN_CI,
|
|
475
176
|
...rules
|
|
476
177
|
}
|
|
477
178
|
},
|
|
@@ -479,7 +180,16 @@ function lsStackEslintCfg({
|
|
|
479
180
|
files: ["*.test.ts", "*.spec.ts"],
|
|
480
181
|
...vitest.configs.recommended
|
|
481
182
|
},
|
|
482
|
-
|
|
183
|
+
{
|
|
184
|
+
files: allowDefaultExport,
|
|
185
|
+
rules: {
|
|
186
|
+
"@ls-stack/no-default-export": OFF
|
|
187
|
+
}
|
|
188
|
+
},
|
|
189
|
+
...extendsConfig,
|
|
190
|
+
{
|
|
191
|
+
ignores: ignore
|
|
192
|
+
}
|
|
483
193
|
);
|
|
484
194
|
}
|
|
485
195
|
export {
|
package/dist/main.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/package.json","../node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/configs/eslint-all.js","../node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/configs/eslint-recommended.js","../node_modules/.pnpm/@eslint+js@9.16.0/node_modules/@eslint/js/src/index.js","../src/main.ts"],"sourcesContent":["{\n \"name\": \"@eslint/js\",\n \"version\": \"9.16.0\",\n \"description\": \"ESLint JavaScript language implementation\",\n \"main\": \"./src/index.js\",\n \"types\": \"./types/index.d.ts\",\n \"scripts\": {\n \"test:types\": \"tsc -p tests/types/tsconfig.json\"\n },\n \"files\": [\n \"LICENSE\",\n \"README.md\",\n \"src\",\n \"types\"\n ],\n \"publishConfig\": {\n \"access\": \"public\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/eslint/eslint.git\",\n \"directory\": \"packages/js\"\n },\n \"homepage\": \"https://eslint.org\",\n \"bugs\": \"https://github.com/eslint/eslint/issues/\",\n \"keywords\": [\n \"javascript\",\n \"eslint-plugin\",\n \"eslint\"\n ],\n \"license\": \"MIT\",\n \"engines\": {\n \"node\": \"^18.18.0 || ^20.9.0 || >=21.1.0\"\n }\n}\n","/*\n * WARNING: This file is autogenerated using the tools/update-eslint-all.js\n * script. Do not edit manually.\n */\n\"use strict\";\n\n/* eslint quote-props: off -- autogenerated so don't lint */\n\n/*\n * IMPORTANT!\n *\n * We cannot add a \"name\" property to this object because it's still used in eslintrc\n * which doesn't support the \"name\" property. If we add a \"name\" property, it will\n * cause an error.\n */\n\nmodule.exports = Object.freeze({\n \"rules\": {\n \"accessor-pairs\": \"error\",\n \"array-callback-return\": \"error\",\n \"arrow-body-style\": \"error\",\n \"block-scoped-var\": \"error\",\n \"camelcase\": \"error\",\n \"capitalized-comments\": \"error\",\n \"class-methods-use-this\": \"error\",\n \"complexity\": \"error\",\n \"consistent-return\": \"error\",\n \"consistent-this\": \"error\",\n \"constructor-super\": \"error\",\n \"curly\": \"error\",\n \"default-case\": \"error\",\n \"default-case-last\": \"error\",\n \"default-param-last\": \"error\",\n \"dot-notation\": \"error\",\n \"eqeqeq\": \"error\",\n \"for-direction\": \"error\",\n \"func-name-matching\": \"error\",\n \"func-names\": \"error\",\n \"func-style\": \"error\",\n \"getter-return\": \"error\",\n \"grouped-accessor-pairs\": \"error\",\n \"guard-for-in\": \"error\",\n \"id-denylist\": \"error\",\n \"id-length\": \"error\",\n \"id-match\": \"error\",\n \"init-declarations\": \"error\",\n \"logical-assignment-operators\": \"error\",\n \"max-classes-per-file\": \"error\",\n \"max-depth\": \"error\",\n \"max-lines\": \"error\",\n \"max-lines-per-function\": \"error\",\n \"max-nested-callbacks\": \"error\",\n \"max-params\": \"error\",\n \"max-statements\": \"error\",\n \"new-cap\": \"error\",\n \"no-alert\": \"error\",\n \"no-array-constructor\": \"error\",\n \"no-async-promise-executor\": \"error\",\n \"no-await-in-loop\": \"error\",\n \"no-bitwise\": \"error\",\n \"no-caller\": \"error\",\n \"no-case-declarations\": \"error\",\n \"no-class-assign\": \"error\",\n \"no-compare-neg-zero\": \"error\",\n \"no-cond-assign\": \"error\",\n \"no-console\": \"error\",\n \"no-const-assign\": \"error\",\n \"no-constant-binary-expression\": \"error\",\n \"no-constant-condition\": \"error\",\n \"no-constructor-return\": \"error\",\n \"no-continue\": \"error\",\n \"no-control-regex\": \"error\",\n \"no-debugger\": \"error\",\n \"no-delete-var\": \"error\",\n \"no-div-regex\": \"error\",\n \"no-dupe-args\": \"error\",\n \"no-dupe-class-members\": \"error\",\n \"no-dupe-else-if\": \"error\",\n \"no-dupe-keys\": \"error\",\n \"no-duplicate-case\": \"error\",\n \"no-duplicate-imports\": \"error\",\n \"no-else-return\": \"error\",\n \"no-empty\": \"error\",\n \"no-empty-character-class\": \"error\",\n \"no-empty-function\": \"error\",\n \"no-empty-pattern\": \"error\",\n \"no-empty-static-block\": \"error\",\n \"no-eq-null\": \"error\",\n \"no-eval\": \"error\",\n \"no-ex-assign\": \"error\",\n \"no-extend-native\": \"error\",\n \"no-extra-bind\": \"error\",\n \"no-extra-boolean-cast\": \"error\",\n \"no-extra-label\": \"error\",\n \"no-fallthrough\": \"error\",\n \"no-func-assign\": \"error\",\n \"no-global-assign\": \"error\",\n \"no-implicit-coercion\": \"error\",\n \"no-implicit-globals\": \"error\",\n \"no-implied-eval\": \"error\",\n \"no-import-assign\": \"error\",\n \"no-inline-comments\": \"error\",\n \"no-inner-declarations\": \"error\",\n \"no-invalid-regexp\": \"error\",\n \"no-invalid-this\": \"error\",\n \"no-irregular-whitespace\": \"error\",\n \"no-iterator\": \"error\",\n \"no-label-var\": \"error\",\n \"no-labels\": \"error\",\n \"no-lone-blocks\": \"error\",\n \"no-lonely-if\": \"error\",\n \"no-loop-func\": \"error\",\n \"no-loss-of-precision\": \"error\",\n \"no-magic-numbers\": \"error\",\n \"no-misleading-character-class\": \"error\",\n \"no-multi-assign\": \"error\",\n \"no-multi-str\": \"error\",\n \"no-negated-condition\": \"error\",\n \"no-nested-ternary\": \"error\",\n \"no-new\": \"error\",\n \"no-new-func\": \"error\",\n \"no-new-native-nonconstructor\": \"error\",\n \"no-new-wrappers\": \"error\",\n \"no-nonoctal-decimal-escape\": \"error\",\n \"no-obj-calls\": \"error\",\n \"no-object-constructor\": \"error\",\n \"no-octal\": \"error\",\n \"no-octal-escape\": \"error\",\n \"no-param-reassign\": \"error\",\n \"no-plusplus\": \"error\",\n \"no-promise-executor-return\": \"error\",\n \"no-proto\": \"error\",\n \"no-prototype-builtins\": \"error\",\n \"no-redeclare\": \"error\",\n \"no-regex-spaces\": \"error\",\n \"no-restricted-exports\": \"error\",\n \"no-restricted-globals\": \"error\",\n \"no-restricted-imports\": \"error\",\n \"no-restricted-properties\": \"error\",\n \"no-restricted-syntax\": \"error\",\n \"no-return-assign\": \"error\",\n \"no-script-url\": \"error\",\n \"no-self-assign\": \"error\",\n \"no-self-compare\": \"error\",\n \"no-sequences\": \"error\",\n \"no-setter-return\": \"error\",\n \"no-shadow\": \"error\",\n \"no-shadow-restricted-names\": \"error\",\n \"no-sparse-arrays\": \"error\",\n \"no-template-curly-in-string\": \"error\",\n \"no-ternary\": \"error\",\n \"no-this-before-super\": \"error\",\n \"no-throw-literal\": \"error\",\n \"no-undef\": \"error\",\n \"no-undef-init\": \"error\",\n \"no-undefined\": \"error\",\n \"no-underscore-dangle\": \"error\",\n \"no-unexpected-multiline\": \"error\",\n \"no-unmodified-loop-condition\": \"error\",\n \"no-unneeded-ternary\": \"error\",\n \"no-unreachable\": \"error\",\n \"no-unreachable-loop\": \"error\",\n \"no-unsafe-finally\": \"error\",\n \"no-unsafe-negation\": \"error\",\n \"no-unsafe-optional-chaining\": \"error\",\n \"no-unused-expressions\": \"error\",\n \"no-unused-labels\": \"error\",\n \"no-unused-private-class-members\": \"error\",\n \"no-unused-vars\": \"error\",\n \"no-use-before-define\": \"error\",\n \"no-useless-assignment\": \"error\",\n \"no-useless-backreference\": \"error\",\n \"no-useless-call\": \"error\",\n \"no-useless-catch\": \"error\",\n \"no-useless-computed-key\": \"error\",\n \"no-useless-concat\": \"error\",\n \"no-useless-constructor\": \"error\",\n \"no-useless-escape\": \"error\",\n \"no-useless-rename\": \"error\",\n \"no-useless-return\": \"error\",\n \"no-var\": \"error\",\n \"no-void\": \"error\",\n \"no-warning-comments\": \"error\",\n \"no-with\": \"error\",\n \"object-shorthand\": \"error\",\n \"one-var\": \"error\",\n \"operator-assignment\": \"error\",\n \"prefer-arrow-callback\": \"error\",\n \"prefer-const\": \"error\",\n \"prefer-destructuring\": \"error\",\n \"prefer-exponentiation-operator\": \"error\",\n \"prefer-named-capture-group\": \"error\",\n \"prefer-numeric-literals\": \"error\",\n \"prefer-object-has-own\": \"error\",\n \"prefer-object-spread\": \"error\",\n \"prefer-promise-reject-errors\": \"error\",\n \"prefer-regex-literals\": \"error\",\n \"prefer-rest-params\": \"error\",\n \"prefer-spread\": \"error\",\n \"prefer-template\": \"error\",\n \"radix\": \"error\",\n \"require-atomic-updates\": \"error\",\n \"require-await\": \"error\",\n \"require-unicode-regexp\": \"error\",\n \"require-yield\": \"error\",\n \"sort-imports\": \"error\",\n \"sort-keys\": \"error\",\n \"sort-vars\": \"error\",\n \"strict\": \"error\",\n \"symbol-description\": \"error\",\n \"unicode-bom\": \"error\",\n \"use-isnan\": \"error\",\n \"valid-typeof\": \"error\",\n \"vars-on-top\": \"error\",\n \"yoda\": \"error\"\n }\n});\n","/**\n * @fileoverview Configuration applied when a user configuration extends from\n * eslint:recommended.\n * @author Nicholas C. Zakas\n */\n\n\"use strict\";\n\n/* eslint sort-keys: [\"error\", \"asc\"] -- Long, so make more readable */\n\n/*\n * IMPORTANT!\n *\n * We cannot add a \"name\" property to this object because it's still used in eslintrc\n * which doesn't support the \"name\" property. If we add a \"name\" property, it will\n * cause an error.\n */\n\nmodule.exports = Object.freeze({\n rules: Object.freeze({\n \"constructor-super\": \"error\",\n \"for-direction\": \"error\",\n \"getter-return\": \"error\",\n \"no-async-promise-executor\": \"error\",\n \"no-case-declarations\": \"error\",\n \"no-class-assign\": \"error\",\n \"no-compare-neg-zero\": \"error\",\n \"no-cond-assign\": \"error\",\n \"no-const-assign\": \"error\",\n \"no-constant-binary-expression\": \"error\",\n \"no-constant-condition\": \"error\",\n \"no-control-regex\": \"error\",\n \"no-debugger\": \"error\",\n \"no-delete-var\": \"error\",\n \"no-dupe-args\": \"error\",\n \"no-dupe-class-members\": \"error\",\n \"no-dupe-else-if\": \"error\",\n \"no-dupe-keys\": \"error\",\n \"no-duplicate-case\": \"error\",\n \"no-empty\": \"error\",\n \"no-empty-character-class\": \"error\",\n \"no-empty-pattern\": \"error\",\n \"no-empty-static-block\": \"error\",\n \"no-ex-assign\": \"error\",\n \"no-extra-boolean-cast\": \"error\",\n \"no-fallthrough\": \"error\",\n \"no-func-assign\": \"error\",\n \"no-global-assign\": \"error\",\n \"no-import-assign\": \"error\",\n \"no-invalid-regexp\": \"error\",\n \"no-irregular-whitespace\": \"error\",\n \"no-loss-of-precision\": \"error\",\n \"no-misleading-character-class\": \"error\",\n \"no-new-native-nonconstructor\": \"error\",\n \"no-nonoctal-decimal-escape\": \"error\",\n \"no-obj-calls\": \"error\",\n \"no-octal\": \"error\",\n \"no-prototype-builtins\": \"error\",\n \"no-redeclare\": \"error\",\n \"no-regex-spaces\": \"error\",\n \"no-self-assign\": \"error\",\n \"no-setter-return\": \"error\",\n \"no-shadow-restricted-names\": \"error\",\n \"no-sparse-arrays\": \"error\",\n \"no-this-before-super\": \"error\",\n \"no-undef\": \"error\",\n \"no-unexpected-multiline\": \"error\",\n \"no-unreachable\": \"error\",\n \"no-unsafe-finally\": \"error\",\n \"no-unsafe-negation\": \"error\",\n \"no-unsafe-optional-chaining\": \"error\",\n \"no-unused-labels\": \"error\",\n \"no-unused-private-class-members\": \"error\",\n \"no-unused-vars\": \"error\",\n \"no-useless-backreference\": \"error\",\n \"no-useless-catch\": \"error\",\n \"no-useless-escape\": \"error\",\n \"no-with\": \"error\",\n \"require-yield\": \"error\",\n \"use-isnan\": \"error\",\n \"valid-typeof\": \"error\"\n })\n});\n","/**\n * @fileoverview Main package entrypoint.\n * @author Nicholas C. Zakas\n */\n\n\"use strict\";\n\nconst { version } = require(\"../package.json\");\n\n//------------------------------------------------------------------------------\n// Public Interface\n//------------------------------------------------------------------------------\n\nmodule.exports = {\n meta: {\n name: \"@eslint/js\",\n version\n },\n configs: {\n all: require(\"./configs/eslint-all\"),\n recommended: require(\"./configs/eslint-recommended\")\n }\n};\n","import eslint from '@eslint/js';\nimport { extendedLintPlugin } from '@ls-stack/extended-lint';\nimport { TSESLint } from '@typescript-eslint/utils';\nimport eslintUnicornPlugin from 'eslint-plugin-unicorn';\nimport vitest from 'eslint-plugin-vitest';\nimport tseslint, { ConfigWithExtends } from 'typescript-eslint';\n\nconst isCI = process.env.CI === 'true';\n\nconst OFF = 0;\nconst WARN = 1;\nconst ERROR = 2;\nconst ERROR_IN_CI = isCI ? ERROR : WARN;\nconst ERROR_IN_CI_ONLY = isCI ? ERROR : 0;\n\nexport const cfgFlags: {\n OFF: 0;\n WARN: 1;\n ERROR: 2;\n ERROR_IN_CI: 0 | 1 | 2;\n ERROR_IN_CI_ONLY: 0 | 1 | 2;\n IS_CI: boolean;\n} = {\n OFF,\n WARN,\n ERROR,\n ERROR_IN_CI,\n ERROR_IN_CI_ONLY,\n IS_CI: isCI,\n};\n\nexport function lsStackEslintCfg({\n extends: extendsConfig = [],\n rules,\n tsconfigRootDir,\n}: {\n extends?: ConfigWithExtends['extends'];\n rules?: ConfigWithExtends['rules'];\n tsconfigRootDir: string;\n}): TSESLint.FlatConfig.ConfigArray {\n return tseslint.config(\n eslint.configs.recommended,\n ...tseslint.configs.recommendedTypeChecked,\n {\n linterOptions: {\n reportUnusedDisableDirectives: true,\n },\n languageOptions: {\n parserOptions: {\n project: './tsconfig.json',\n tsconfigRootDir,\n },\n globals: { process: true },\n },\n },\n {\n plugins: {\n '@lucasols/extended-lint': extendedLintPlugin,\n unicorn: eslintUnicornPlugin,\n vitest,\n },\n\n rules: {\n 'no-warning-comments': [ERROR_IN_CI, { terms: ['FIX:'] }],\n 'no-constant-binary-expression': ERROR_IN_CI,\n 'object-shorthand': ERROR_IN_CI,\n 'no-useless-rename': ERROR_IN_CI,\n 'no-param-reassign': ERROR_IN_CI,\n 'prefer-template': ERROR_IN_CI,\n 'prefer-const': [ERROR_IN_CI, { destructuring: 'all' }],\n\n 'no-prototype-builtins': OFF,\n 'no-inner-declarations': OFF,\n 'no-undef': OFF,\n 'no-console': [ERROR_IN_CI, { allow: ['warn', 'error', 'info'] }],\n 'no-restricted-imports': [\n ERROR_IN_CI,\n {\n patterns: [\n {\n group: ['*.test'],\n message: 'Do not import test files',\n },\n ],\n },\n ],\n 'no-restricted-syntax': [\n ERROR_IN_CI_ONLY,\n {\n selector: 'CallExpression[callee.property.name=\"only\"]',\n message: 'No test.only',\n },\n {\n selector: 'CallExpression[callee.property.name=\"todo\"]',\n message: 'No test.todo',\n },\n ],\n 'no-implicit-coercion': [\n ERROR_IN_CI,\n { disallowTemplateShorthand: true, allow: ['!!'] },\n ],\n\n /* typescript */\n '@typescript-eslint/no-unnecessary-condition': ERROR_IN_CI,\n '@typescript-eslint/naming-convention': [\n 'error',\n {\n selector: 'typeLike',\n format: ['PascalCase'],\n },\n ],\n '@typescript-eslint/only-throw-error': ERROR_IN_CI,\n '@typescript-eslint/no-unused-expressions': ERROR_IN_CI,\n '@typescript-eslint/no-unused-vars': [\n ERROR_IN_CI,\n {\n argsIgnorePattern: '_^',\n ignoreRestSiblings: true,\n varsIgnorePattern: '_^',\n },\n ],\n '@typescript-eslint/no-shadow': [\n ERROR_IN_CI,\n { ignoreOnInitialization: true, allow: ['expect'] },\n ],\n\n /* extended-lint */\n '@lucasols/extended-lint/no-unused-type-props-in-args': ERROR_IN_CI,\n\n ...rules,\n },\n },\n {\n files: ['*.test.ts', '*.spec.ts'],\n ...vitest.configs.recommended,\n },\n ...extendsConfig,\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA,MACE,MAAQ;AAAA,MACR,SAAW;AAAA,MACX,aAAe;AAAA,MACf,MAAQ;AAAA,MACR,OAAS;AAAA,MACT,SAAW;AAAA,QACT,cAAc;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E,UAAU;AAAA,YACV,SAAS;AAAA,UACX;AAAA,UACA;AAAA,YACE,UAAU;AAAA,YACV,SAAS;AAAA,UACX;AAAA,QACF;AAAA,QACA,wBAAwB;AAAA,UACtB;AAAA,UACA,EAAE,2BAA2B,MAAM,OAAO,CAAC,IAAI,EAAE;AAAA,QACnD;AAAA;AAAA,QAGA,+CAA+C;AAAA,QAC/C,wCAAwC;AAAA,UACtC;AAAA,UACA;AAAA,YACE,UAAU;AAAA,YACV,QAAQ,CAAC,YAAY;AAAA,UACvB;AAAA,QACF;AAAA,QACA,uCAAuC;AAAA,QACvC,4CAA4C;AAAA,QAC5C,qCAAqC;AAAA,UACnC;AAAA,UACA;AAAA,YACE,mBAAmB;AAAA,YACnB,oBAAoB;AAAA,YACpB,mBAAmB;AAAA,UACrB;AAAA,QACF;AAAA,QACA,gCAAgC;AAAA,UAC9B;AAAA,UACA,EAAE,wBAAwB,MAAM,OAAO,CAAC,QAAQ,EAAE;AAAA,QACpD;AAAA;AAAA,QAGA,wDAAwD;AAAA,QAExD,GAAG;AAAA,MACL;AAAA,IACF;AAAA,IACA;AAAA,MACE,OAAO,CAAC,aAAa,WAAW;AAAA,MAChC,GAAG,OAAO,QAAQ;AAAA,IACpB;AAAA,IACA,GAAG;AAAA,EACL;AACF;","names":["eslint"]}
|
|
1
|
+
{"version":3,"sources":["../src/main.ts"],"sourcesContent":["import eslint from '@eslint/js';\nimport { extendedLintPlugin } from '@ls-stack/extended-lint';\nimport { TSESLint } from '@typescript-eslint/utils';\nimport eslintUnicornPlugin from 'eslint-plugin-unicorn';\nimport vitest from 'eslint-plugin-vitest';\nimport tseslint, { ConfigWithExtends } from 'typescript-eslint';\n\nconst isCI = process.env.CI === 'true';\n\nconst OFF = 0;\nconst WARN = 1;\nconst ERROR = 2;\nconst ERROR_IN_CI = isCI ? ERROR : WARN;\nconst ERROR_IN_CI_ONLY = isCI ? ERROR : 0;\nconst errorOnExpiringTodos = process.env.EXPIRING_TODOS === 'true' || !isCI;\n\nexport const cfgFlags: {\n OFF: 0;\n WARN: 1;\n ERROR: 2;\n ERROR_IN_CI: 0 | 1 | 2;\n ERROR_IN_CI_ONLY: 0 | 1 | 2;\n IS_CI: boolean;\n} = {\n OFF,\n WARN,\n ERROR,\n ERROR_IN_CI,\n ERROR_IN_CI_ONLY,\n IS_CI: isCI,\n};\n\n/**\n * Plugins:\n *\n * Use @ls-stack/{rule} to change ls-stack rules.\n * Use unicorn/{rule} to change unicorn rules.\n *\n * Env vars:\n * CI: if true, will be more strict.\n * EXPIRING_TODOS: if true, will not allow expiring todos.\n */\nexport function lsStackEslintCfg({\n extends: extendsConfig = [],\n rules,\n tsconfigRootDir,\n ignore = [],\n allowDefaultExport = ['eslint.config.{js,cjs,mjs,ts}'],\n}: {\n extends?: ConfigWithExtends['extends'];\n rules?: ConfigWithExtends['rules'];\n tsconfigRootDir: string;\n ignore?: string[];\n allowDefaultExport?: string[];\n}): TSESLint.FlatConfig.ConfigArray {\n return tseslint.config(\n eslint.configs.recommended,\n ...tseslint.configs.recommendedTypeChecked,\n {\n linterOptions: {\n reportUnusedDisableDirectives: true,\n },\n languageOptions: {\n parserOptions: {\n project: './tsconfig.json',\n tsconfigRootDir,\n },\n globals: { process: true },\n },\n },\n {\n plugins: {\n '@ls-stack': extendedLintPlugin,\n unicorn: eslintUnicornPlugin,\n vitest,\n },\n\n rules: {\n 'no-warning-comments': [ERROR_IN_CI, { terms: ['FIX:'] }],\n 'no-constant-binary-expression': ERROR_IN_CI,\n 'object-shorthand': ERROR_IN_CI,\n 'no-useless-rename': ERROR_IN_CI,\n 'no-param-reassign': ERROR_IN_CI,\n 'prefer-template': ERROR_IN_CI,\n 'prefer-const': [ERROR_IN_CI, { destructuring: 'all' }],\n\n 'no-prototype-builtins': OFF,\n 'no-inner-declarations': OFF,\n 'no-undef': OFF,\n 'no-console': [ERROR_IN_CI, { allow: ['warn', 'error', 'info'] }],\n 'no-restricted-imports': [\n ERROR_IN_CI,\n {\n patterns: [\n {\n group: ['*.test'],\n message: 'Do not import test files',\n },\n ],\n },\n ],\n 'no-restricted-syntax': [\n ERROR_IN_CI_ONLY,\n {\n selector: 'CallExpression[callee.property.name=\"only\"]',\n message: 'No test.only',\n },\n {\n selector: 'CallExpression[callee.property.name=\"todo\"]',\n message: 'No test.todo',\n },\n ],\n 'no-implicit-coercion': [\n ERROR_IN_CI,\n { disallowTemplateShorthand: true, allow: ['!!'] },\n ],\n\n /* typescript */\n '@typescript-eslint/no-unnecessary-condition': ERROR_IN_CI,\n '@typescript-eslint/no-non-null-assertion': ERROR_IN_CI,\n '@typescript-eslint/consistent-type-assertions': [\n ERROR,\n {\n assertionStyle: 'never',\n },\n ],\n '@typescript-eslint/naming-convention': [\n 'error',\n {\n selector: 'typeLike',\n format: ['PascalCase'],\n },\n ],\n '@typescript-eslint/only-throw-error': ERROR_IN_CI,\n '@typescript-eslint/no-unused-expressions': ERROR_IN_CI,\n '@typescript-eslint/no-unused-vars': [\n ERROR_IN_CI,\n {\n argsIgnorePattern: '_$',\n ignoreRestSiblings: true,\n varsIgnorePattern: '_$',\n },\n ],\n '@typescript-eslint/no-shadow': [\n ERROR_IN_CI,\n { ignoreOnInitialization: true, allow: ['expect'] },\n ],\n '@typescript-eslint/no-unsafe-assignment': OFF,\n\n 'unicorn/expiring-todo-comments': [\n ERROR_IN_CI,\n {\n terms: [\n 'FIX',\n // 'TODO',\n 'palinter-ignore-unused-next-line',\n 'palinter-ignore-not-have-direct-circular-deps',\n 'palinter-ignore-not-have-circular-deps',\n 'palinter-ignore-not-have-unused-exports',\n ],\n ignore: [/^ HACK:/],\n allowWarningComments: false,\n ...(!errorOnExpiringTodos && { date: '2000-01-01' }),\n },\n ],\n 'unicorn/require-array-join-separator': ERROR_IN_CI,\n 'unicorn/no-empty-file': ERROR_IN_CI,\n 'unicorn/no-array-reduce': [\n ERROR_IN_CI,\n { allowSimpleOperations: true },\n ],\n 'unicorn/no-array-for-each': ERROR_IN_CI,\n\n /* extended-lint */\n '@ls-stack/no-unused-type-props-in-args': ERROR,\n '@ls-stack/improved-no-unnecessary-condition': ERROR,\n '@ls-stack/no-optional-root-props': ERROR_IN_CI,\n '@ls-stack/prefer-single-line-if': [\n WARN,\n { maxLineLength: 80, maxNonSimpleConditionLength: 40 },\n ],\n '@ls-stack/prefer-named-functions': [WARN, { ignoreRegex: 'Fn$' }],\n '@ls-stack/require-description': [ERROR, { ignore: ['eslint'] }],\n '@ls-stack/no-default-export': ERROR,\n '@ls-stack/no-unnecessary-casting': [\n ERROR_IN_CI,\n {\n additionalCastFunctions: [\n { name: 'castToString', expectedType: 'string' },\n { name: 'castToNumber', expectedType: 'number' },\n ],\n },\n ],\n '@ls-stack/no-type-guards': [\n ERROR,\n {\n alternativeMsgs: {\n inArrayFilter: 'Use filterWithNarrowing instead',\n inArrayFind: 'Use findWithNarrowing instead',\n },\n },\n ],\n '@ls-stack/use-top-level-regex': ERROR,\n '@ls-stack/use-types-directly-above-usage': [ERROR],\n\n /* vitest */\n 'vitest/expect-expect': ERROR_IN_CI,\n 'vitest/no-identical-title': ERROR_IN_CI,\n\n ...rules,\n },\n },\n {\n files: ['*.test.ts', '*.spec.ts'],\n ...vitest.configs.recommended,\n },\n {\n files: allowDefaultExport,\n rules: {\n '@ls-stack/no-default-export': OFF,\n },\n },\n ...extendsConfig,\n {\n ignores: ignore,\n },\n );\n}\n"],"mappings":";AAAA,OAAO,YAAY;AACnB,SAAS,0BAA0B;AAEnC,OAAO,yBAAyB;AAChC,OAAO,YAAY;AACnB,OAAO,cAAqC;AAE5C,IAAM,OAAO,QAAQ,IAAI,OAAO;AAEhC,IAAM,MAAM;AACZ,IAAM,OAAO;AACb,IAAM,QAAQ;AACd,IAAM,cAAc,OAAO,QAAQ;AACnC,IAAM,mBAAmB,OAAO,QAAQ;AACxC,IAAM,uBAAuB,QAAQ,IAAI,mBAAmB,UAAU,CAAC;AAEhE,IAAM,WAOT;AAAA,EACF;AAAA,EACA;AAAA,EACA;AAAA,EACA;AA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AAC;AAAA,QACjE,iCAAiC,CAAC,OAAO,EAAE,QAAQ,CAAC,QAAQ,EAAE,CAAC;AAAA,QAC/D,+BAA+B;AAAA,QAC/B,oCAAoC;AAAA,UAClC;AAAA,UACA;AAAA,YACE,yBAAyB;AAAA,cACvB,EAAE,MAAM,gBAAgB,cAAc,SAAS;AAAA,cAC/C,EAAE,MAAM,gBAAgB,cAAc,SAAS;AAAA,YACjD;AAAA,UACF;AAAA,QACF;AAAA,QACA,4BAA4B;AAAA,UAC1B;AAAA,UACA;AAAA,YACE,iBAAiB;AAAA,cACf,eAAe;AAAA,cACf,aAAa;AAAA,YACf;AAAA,UACF;AAAA,QACF;AAAA,QACA,iCAAiC;AAAA,QACjC,4CAA4C,CAAC,KAAK;AAAA;AAAA,QAGlD,wBAAwB;AAAA,QACxB,6BAA6B;AAAA,QAE7B,GAAG;AAAA,MACL;AAAA,IACF;AAAA,IACA;AAAA,MACE,OAAO,CAAC,aAAa,WAAW;AAAA,MAChC,GAAG,OAAO,QAAQ;AAAA,IACpB;AAAA,IACA;AAAA,MACE,OAAO;AAAA,MACP,OAAO;AAAA,QACL,+BAA+B;AAAA,MACjC;AAAA,IACF;AAAA,IACA,GAAG;AAAA,IACH;AAAA,MACE,SAAS;AAAA,IACX;AAAA,EACF;AACF;","names":[]}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ls-stack/eslint-cfg",
|
|
3
3
|
"description": "Eslint cfg preset of @ls-stack packages",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.2.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist"
|
|
@@ -23,22 +23,23 @@
|
|
|
23
23
|
"node": ">=21.5.0"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@ls-stack/utils": "^
|
|
27
|
-
"@types/node": "^
|
|
28
|
-
"prettier": "3.
|
|
29
|
-
"prettier-plugin-organize-imports": "^4.
|
|
30
|
-
"tsup": "^8.
|
|
31
|
-
"typescript": "5.
|
|
32
|
-
"@types/eslint": "^9.6.1"
|
|
33
|
-
"@types/eslint__js": "^8.42.3"
|
|
26
|
+
"@ls-stack/utils": "^3.36.0",
|
|
27
|
+
"@types/node": "^24.3.0",
|
|
28
|
+
"prettier": "3.6.2",
|
|
29
|
+
"prettier-plugin-organize-imports": "^4.2.0",
|
|
30
|
+
"tsup": "^8.5.0",
|
|
31
|
+
"typescript": "5.9.2",
|
|
32
|
+
"@types/eslint": "^9.6.1"
|
|
34
33
|
},
|
|
35
34
|
"dependencies": {
|
|
36
|
-
"@
|
|
37
|
-
"@
|
|
38
|
-
"@typescript-eslint/
|
|
39
|
-
"typescript-eslint": "^8.
|
|
40
|
-
"eslint": "^
|
|
41
|
-
"eslint
|
|
35
|
+
"@eslint/js": "^9.33.0",
|
|
36
|
+
"@ls-stack/extended-lint": "^0.60.1",
|
|
37
|
+
"@typescript-eslint/eslint-plugin": "^8.40.0",
|
|
38
|
+
"@typescript-eslint/parser": "^8.40.0",
|
|
39
|
+
"@typescript-eslint/utils": "^8.40.0",
|
|
40
|
+
"typescript-eslint": "^8.40.0",
|
|
41
|
+
"eslint": "^9.33.0",
|
|
42
|
+
"eslint-plugin-unicorn": "^60.0.0",
|
|
42
43
|
"eslint-plugin-vitest": "^0.5.4"
|
|
43
44
|
},
|
|
44
45
|
"scripts": {
|