@eslinted/core 3.1.2 → 3.1.3
Sign up to get free protection for your applications and to get access to all the features.
- package/package.json +2 -2
- package/dist/factory/ruleset/index.d.ts +0 -13
- package/dist/factory/ruleset/index.d.ts.map +0 -1
- package/dist/factory/ruleset/index.js +0 -38
- package/dist/factory/ruleset/index.js.map +0 -1
- package/dist/factory/ruleset/rule/index.d.ts +0 -7
- package/dist/factory/ruleset/rule/index.d.ts.map +0 -1
- package/dist/factory/ruleset/rule/index.js +0 -9
- package/dist/factory/ruleset/rule/index.js.map +0 -1
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"_schemaVersion": "20.15.0",
|
3
3
|
"name": "@eslinted/core",
|
4
|
-
"version": "3.1.
|
4
|
+
"version": "3.1.3",
|
5
5
|
"description": "Core ESLint flat config factory npm package `linted`.",
|
6
6
|
"keywords": [],
|
7
7
|
"license": "MIT",
|
@@ -26,7 +26,7 @@
|
|
26
26
|
},
|
27
27
|
"devDependencies": {
|
28
28
|
"eslint": "~9.9.0",
|
29
|
-
"linted": "~16.2.
|
29
|
+
"linted": "~16.2.1",
|
30
30
|
"npm-run-all": "^4.1.5",
|
31
31
|
"typescript": "^5.5.4"
|
32
32
|
},
|
@@ -1,13 +0,0 @@
|
|
1
|
-
import type { Scope } from "../../scopes/index.js";
|
2
|
-
import Rule from "./rule/index.js";
|
3
|
-
export { Rule };
|
4
|
-
export default class Ruleset<S extends Scope> {
|
5
|
-
private readonly scope;
|
6
|
-
readonly ruleset: readonly Rule[];
|
7
|
-
overrides: Null<Rule>;
|
8
|
-
constructor(scope: literalful<S>, ...rules: readonly Rule[]);
|
9
|
-
get id(): literalful<S>;
|
10
|
-
get records(): (readonly [string, Readonly<Record<string, import("../../boundary/input/rules/preset/entry/object/state/index.js").Level | readonly [import("../../boundary/input/rules/preset/entry/object/state/index.js").Level, ...unknown[]]>>])[];
|
11
|
-
override(overrides: undefined | Rule["rules"]): this;
|
12
|
-
}
|
13
|
-
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/factory/ruleset/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,IAAI,MAAM,iBAAiB,CAAC;AAEnC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO,CAAC,CAAC,SAAS,KAAK;IAI9B,OAAO,CAAC,QAAQ,CAAC,KAAK;IAHlC,SAAgB,OAAO,EAAE,SAAS,IAAI,EAAE,CAAC;IAClC,SAAS,EAAE,IAAI,CAAC,IAAI,CAAC,CAAQ;gBAEP,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,EAAE,GAAG,KAAK,EAAE,SAAS,IAAI,EAAE;IAO5E,IAAW,EAAE,kBAIZ;IAED,IAAW,OAAO,4OAUjB;IAEM,QAAQ,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC;CAMrD"}
|
@@ -1,38 +0,0 @@
|
|
1
|
-
import Rule from "./rule/index.js";
|
2
|
-
export { Rule };
|
3
|
-
export default class Ruleset {
|
4
|
-
scope;
|
5
|
-
ruleset;
|
6
|
-
overrides = null;
|
7
|
-
constructor(scope, ...rules) {
|
8
|
-
this.scope = scope;
|
9
|
-
try {
|
10
|
-
this.ruleset = [...rules];
|
11
|
-
}
|
12
|
-
catch (e) {
|
13
|
-
throw new Error(`linted.factory.Ruleset`, { cause: e });
|
14
|
-
}
|
15
|
-
}
|
16
|
-
get id() {
|
17
|
-
const { scope } = this;
|
18
|
-
return scope;
|
19
|
-
}
|
20
|
-
get records() {
|
21
|
-
try {
|
22
|
-
const { ruleset, overrides } = this;
|
23
|
-
return [
|
24
|
-
...ruleset.map(rules => [rules.id, rules.rules]),
|
25
|
-
...overrides === null ? [] : [[overrides.id, overrides.rules]],
|
26
|
-
];
|
27
|
-
}
|
28
|
-
catch (e) {
|
29
|
-
throw new Error(`linted.factory.Ruleset: records`, { cause: e });
|
30
|
-
}
|
31
|
-
}
|
32
|
-
override(overrides) {
|
33
|
-
if (typeof overrides !== "undefined")
|
34
|
-
this.overrides = new Rule("override", overrides);
|
35
|
-
return this;
|
36
|
-
}
|
37
|
-
}
|
38
|
-
//# sourceMappingURL=index.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/factory/ruleset/index.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,iBAAiB,CAAC;AAEnC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO;IAIG;IAHb,OAAO,CAAkB;IAClC,SAAS,GAAe,IAAI,CAAC;IAEpC,YAA6B,KAAoB,EAAE,GAAG,KAAsB;QAA/C,UAAK,GAAL,KAAK,CAAe;QAC/C,IAAI,CAAC;YACH,IAAI,CAAC,OAAO,GAAG,CAAC,GAAG,KAAK,CAAC,CAAC;QAC5B,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YAAC,MAAM,IAAI,KAAK,CAAC,wBAAwB,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC;QAAC,CAAC;IACxE,CAAC;IAED,IAAW,EAAE;QACX,MAAM,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC;QAEvB,OAAO,KAAK,CAAC;IACf,CAAC;IAED,IAAW,OAAO;QAChB,IAAI,CAAC;YACH,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,GAAG,IAAI,CAAC;YAEpC,OAAO;gBACL,GAAG,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,EAAE,EAAE,KAAK,CAAC,KAAK,CAAU,CAAC;gBACzD,GAAG,SAAS,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,EAAE,EAAE,SAAS,CAAC,KAAK,CAAU,CAAU;aACjF,CAAC;QACJ,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YAAC,MAAM,IAAI,KAAK,CAAC,iCAAiC,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC;QAAC,CAAC;IACjF,CAAC;IAEM,QAAQ,CAAC,SAAoC;QAClD,IAAI,OAAO,SAAS,KAAK,WAAW;YAClC,IAAI,CAAC,SAAS,GAAG,IAAI,IAAI,CAAC,UAAU,EAAE,SAAS,CAAC,CAAC;QAEnD,OAAO,IAAI,CAAC;IACd,CAAC;CACF"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/factory/ruleset/rule/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,4BAA4B,CAAC;AAExD,MAAM,CAAC,OAAO;aAEM,EAAE,EAAE,MAAM;aACV,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM;gBADtC,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM;CAEzD"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/factory/ruleset/rule/index.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO;IAEM;IACA;IAFlB,YACkB,EAAU,EACV,KAAsC;QADtC,OAAE,GAAF,EAAE,CAAQ;QACV,UAAK,GAAL,KAAK,CAAiC;IACrD,CAAC;CACL"}
|