@eslinted/core 0.8.1 → 0.9.0-rc.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/boundary/boundary.d.ts +5 -10
- package/dist/boundary/boundary.d.ts.map +1 -1
- package/dist/boundary/boundary.js +2 -1
- package/dist/boundary/boundary.js.map +1 -1
- package/dist/boundary/input/input.d.ts +4 -7
- package/dist/boundary/input/input.d.ts.map +1 -1
- package/dist/boundary/input/parsers/parsers.d.ts +2 -2
- package/dist/boundary/input/parsers/parsers.d.ts.map +1 -1
- package/dist/boundary/input/plugins/plugins.d.ts +1 -2
- package/dist/boundary/input/plugins/plugins.d.ts.map +1 -1
- package/dist/boundary/output/output.d.ts +2 -2
- package/dist/boundary/output/output.d.ts.map +1 -1
- package/dist/boundary/scopes/scopes.d.ts.map +1 -0
- package/dist/boundary/scopes/scopes.js.map +1 -0
- package/dist/factory/Factory.d.ts +7 -0
- package/dist/factory/Factory.d.ts.map +1 -0
- package/dist/factory/{factory.js → Factory.js} +3 -3
- package/dist/factory/Factory.js.map +1 -0
- package/dist/factory/files/Files.d.ts +1 -1
- package/dist/factory/files/Files.d.ts.map +1 -1
- package/dist/factory/files/Files.js +4 -9
- package/dist/factory/files/Files.js.map +1 -1
- package/dist/factory/options/Options.d.ts +3 -1
- package/dist/factory/options/Options.d.ts.map +1 -1
- package/dist/factory/options/Options.js +1 -1
- package/dist/factory/options/Options.js.map +1 -1
- package/dist/factory/options/option/Option.d.ts +22 -8
- package/dist/factory/options/option/Option.d.ts.map +1 -1
- package/dist/factory/options/option/Option.js +23 -33
- package/dist/factory/options/option/Option.js.map +1 -1
- package/dist/factory/options/option/html/index.d.ts.map +1 -1
- package/dist/factory/options/option/html/index.js +2 -7
- package/dist/factory/options/option/html/index.js.map +1 -1
- package/dist/factory/options/option/js/index.d.ts.map +1 -1
- package/dist/factory/options/option/js/index.js +4 -9
- package/dist/factory/options/option/js/index.js.map +1 -1
- package/dist/factory/options/option/json/index.d.ts.map +1 -1
- package/dist/factory/options/option/json/index.js +2 -7
- package/dist/factory/options/option/json/index.js.map +1 -1
- package/dist/factory/options/option/jsonc/index.d.ts.map +1 -1
- package/dist/factory/options/option/jsonc/index.js +2 -7
- package/dist/factory/options/option/jsonc/index.js.map +1 -1
- package/dist/factory/options/option/svelte/index.d.ts.map +1 -1
- package/dist/factory/options/option/svelte/index.js +11 -16
- package/dist/factory/options/option/svelte/index.js.map +1 -1
- package/dist/factory/options/option/ts/index.d.ts.map +1 -1
- package/dist/factory/options/option/ts/index.js +9 -14
- package/dist/factory/options/option/ts/index.js.map +1 -1
- package/dist/factory/options/option/yml/index.d.ts.map +1 -1
- package/dist/factory/options/option/yml/index.js +2 -7
- package/dist/factory/options/option/yml/index.js.map +1 -1
- package/dist/factory/ruleset/Ruleset.d.ts +1 -1
- package/dist/factory/ruleset/Ruleset.d.ts.map +1 -1
- package/dist/factory/ruleset/Ruleset.js +11 -31
- package/dist/factory/ruleset/Ruleset.js.map +1 -1
- package/dist/index.d.ts +5 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/boundary/boundary.ts +11 -0
- package/src/boundary/input/input.ts +5 -0
- package/src/boundary/input/{parsers.ts → parsers/parsers.ts} +2 -2
- package/src/boundary/input/{plugins.ts → plugins/plugins.ts} +1 -2
- package/src/boundary/output/output.ts +3 -0
- package/src/factory/Factory.ts +13 -0
- package/src/factory/files/Files.ts +5 -13
- package/src/factory/options/{options.ts → Options.ts} +2 -0
- package/src/factory/options/option/Option.ts +51 -71
- package/src/factory/options/option/html/index.ts +2 -10
- package/src/factory/options/option/js/index.ts +4 -12
- package/src/factory/options/option/json/index.ts +2 -10
- package/src/factory/options/option/jsonc/index.ts +2 -10
- package/src/factory/options/option/svelte/index.ts +11 -19
- package/src/factory/options/option/ts/index.ts +9 -17
- package/src/factory/options/option/yml/index.ts +2 -10
- package/src/factory/ruleset/Ruleset.ts +15 -47
- package/src/index.ts +13 -9
- package/dist/boundary/input/parsers.d.ts +0 -7
- package/dist/boundary/input/parsers.d.ts.map +0 -1
- package/dist/boundary/input/parsers.js +0 -2
- package/dist/boundary/input/parsers.js.map +0 -1
- package/dist/boundary/input/plugins.d.ts +0 -7
- package/dist/boundary/input/plugins.d.ts.map +0 -1
- package/dist/boundary/input/plugins.js +0 -2
- package/dist/boundary/input/plugins.js.map +0 -1
- package/dist/boundary/input.d.ts +0 -8
- package/dist/boundary/input.d.ts.map +0 -1
- package/dist/boundary/input.js +0 -2
- package/dist/boundary/input.js.map +0 -1
- package/dist/boundary/output/IConfig.d.ts +0 -19
- package/dist/boundary/output/IConfig.d.ts.map +0 -1
- package/dist/boundary/output/IConfig.js +0 -2
- package/dist/boundary/output/IConfig.js.map +0 -1
- package/dist/boundary/output.d.ts +0 -3
- package/dist/boundary/output.d.ts.map +0 -1
- package/dist/boundary/output.js +0 -2
- package/dist/boundary/output.js.map +0 -1
- package/dist/factory/factory.d.ts +0 -5
- package/dist/factory/factory.d.ts.map +0 -1
- package/dist/factory/factory.js.map +0 -1
- package/dist/scopes/scopes.d.ts.map +0 -1
- package/dist/scopes/scopes.js.map +0 -1
- package/src/boundary/input.ts +0 -9
- package/src/boundary/output.ts +0 -3
- package/src/factory/factory.ts +0 -10
- /package/dist/{scopes → boundary/scopes}/scopes.d.ts +0 -0
- /package/dist/{scopes → boundary/scopes}/scopes.js +0 -0
- /package/src/boundary/output/{IConfig.ts → config/IConfig.ts} +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/IOption.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/language/IOLanguage.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/language/ecma/IOLanguageEcma.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/language/globals/IOLanguageGlobals.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/language/source/IOLanguageSource.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/linter/IOLinter.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/plugins/IOPlugins.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/option/processor/IOProcessor.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/rules/IRule.d.ts +0 -0
- /package/src/boundary/output/{interface → config/interface}/rules/state/RuleSeverity.d.ts +0 -0
- /package/src/{scopes → boundary/scopes}/scopes.ts +0 -0
package/src/index.ts
CHANGED
@@ -1,23 +1,27 @@
|
|
1
|
-
import scopes
|
2
|
-
import type
|
3
|
-
|
1
|
+
import scopes from "./boundary/boundary.js";
|
2
|
+
import type {
|
3
|
+
Scope,
|
4
|
+
Plugins,
|
5
|
+
Parsers,
|
6
|
+
IConfig,
|
7
|
+
} from "./boundary/boundary.js";
|
4
8
|
import {
|
5
9
|
Options,
|
6
10
|
Files,
|
7
11
|
Ruleset,
|
8
12
|
Rule,
|
9
|
-
} from "./factory/
|
13
|
+
} from "./factory/Factory.js";
|
10
14
|
|
11
|
-
export type { Scope
|
15
|
+
export type { Scope };
|
12
16
|
export { Ruleset, Rule };
|
13
17
|
export default function (
|
14
|
-
plugins:
|
15
|
-
parsers:
|
18
|
+
plugins: Plugins,
|
19
|
+
parsers: Parsers,
|
16
20
|
base: Record<Scope, string[]>,
|
17
21
|
includes: Particord<Scope, string[]>,
|
18
22
|
rulesets: { [S in Scope]: Ruleset<S> },
|
19
23
|
overrides: Particord<Scope, IRule>,
|
20
|
-
):
|
24
|
+
): IConfig[] {
|
21
25
|
try {
|
22
26
|
const files = new Files(
|
23
27
|
base,
|
@@ -103,7 +107,7 @@ export default function (
|
|
103
107
|
}
|
104
108
|
catch (e) {
|
105
109
|
throw new Error(
|
106
|
-
`linted
|
110
|
+
`linted(): Caught exception.`,
|
107
111
|
{ cause: e },
|
108
112
|
);
|
109
113
|
}
|
@@ -1,7 +0,0 @@
|
|
1
|
-
import type { Scope } from "../../scopes/scopes.js";
|
2
|
-
import type { Options } from "../../factory/factory.js";
|
3
|
-
type Parsers = {
|
4
|
-
readonly [S in Scope]: ConstructorParameters<typeof Options[S]>[2] extends readonly [unknown, ...unknown[]] ? unknown : null;
|
5
|
-
};
|
6
|
-
export type { Parsers as default };
|
7
|
-
//# sourceMappingURL=parsers.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"parsers.d.ts","sourceRoot":"","sources":["../../../src/boundary/input/parsers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AACpD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AAExD,KAAK,OAAO,GAAG;IACb,QAAQ,EAAE,CAAC,IAAI,KAAK,GAAG,qBAAqB,CAAC,OAAO,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,SAAS,CAAC,OAAO,EAAE,GAAG,OAAO,EAAE,CAAC,GACvG,OAAO,GACP,IAAI;CACT,CAAC;AAEF,YAAY,EAAE,OAAO,IAAI,OAAO,EAAE,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"parsers.js","sourceRoot":"","sources":["../../../src/boundary/input/parsers.ts"],"names":[],"mappings":""}
|
@@ -1,7 +0,0 @@
|
|
1
|
-
import type { Scope } from "../../scopes/scopes.js";
|
2
|
-
import type { Options } from "../../factory/factory.js";
|
3
|
-
type Plugins = {
|
4
|
-
readonly [S in Scope]: InstanceType<typeof Options[S]>["plugins"];
|
5
|
-
};
|
6
|
-
export type { Plugins as default };
|
7
|
-
//# sourceMappingURL=plugins.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"plugins.d.ts","sourceRoot":"","sources":["../../../src/boundary/input/plugins.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AACpD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AAExD,KAAK,OAAO,GAAG;IACb,QAAQ,EAAE,CAAC,IAAI,KAAK,GAAG,YAAY,CAAC,OAAO,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;CAClE,CAAC;AAEF,YAAY,EAAE,OAAO,IAAI,OAAO,EAAE,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"plugins.js","sourceRoot":"","sources":["../../../src/boundary/input/plugins.ts"],"names":[],"mappings":""}
|
package/dist/boundary/input.d.ts
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"input.d.ts","sourceRoot":"","sources":["../../src/boundary/input.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,OAAO,MAAM,oBAAoB,CAAC;AAC9C,OAAO,KAAK,OAAO,MAAM,oBAAoB,CAAC;AAE9C,kBAAU,KAAK,CAAC;IACd,KAAY,OAAO,GAAG,OAAO,CAAC;IAC9B,KAAY,OAAO,GAAG,OAAO,CAAC;CAC/B;AAED,YAAY,EAAE,KAAK,IAAI,OAAO,EAAE,CAAC"}
|
package/dist/boundary/input.js
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"input.js","sourceRoot":"","sources":["../../src/boundary/input.ts"],"names":[],"mappings":""}
|
@@ -1,19 +0,0 @@
|
|
1
|
-
export default interface IConfig {
|
2
|
-
name: `scope:${string}/rule:${string}+${string}`;
|
3
|
-
rules: IRule;
|
4
|
-
files: readonly string[];
|
5
|
-
linterOptions: {
|
6
|
-
noInlineConfig: true;
|
7
|
-
reportUnusedDisableDirectives: "error";
|
8
|
-
};
|
9
|
-
languageOptions: {
|
10
|
-
sourceType?: "module" | "script";
|
11
|
-
ecmaVersion?: "latest";
|
12
|
-
globals?: Record<string, true>;
|
13
|
-
parser?: unknown;
|
14
|
-
parserOptions?: Record<string, unknown>;
|
15
|
-
};
|
16
|
-
plugins: Record<string, Record<"configs", unknown>>;
|
17
|
-
processor?: string;
|
18
|
-
}
|
19
|
-
//# sourceMappingURL=IConfig.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"IConfig.d.ts","sourceRoot":"","sources":["../../../src/boundary/output/IConfig.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,WAAW,OAAO;IAC9B,IAAI,EAAE,SAAS,MAAM,SAAS,MAAM,IAAI,MAAM,EAAE,CAAC;IACjD,KAAK,EAAE,KAAK,CAAC;IACb,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;IACzB,aAAa,EAAE;QACb,cAAc,EAAE,IAAI,CAAC;QACrB,6BAA6B,EAAE,OAAO,CAAC;KACxC,CAAC;IACF,eAAe,EAAE;QACf,UAAU,CAAC,EACP,QAAQ,GACR,QAAQ,CAAC;QACb,WAAW,CAAC,EAAE,QAAQ,CAAC;QACvB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;QAC/B,MAAM,CAAC,EAAE,OAAO,CAAC;QACjB,aAAa,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACzC,CAAC;IACF,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC,CAAC;IACpD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"IConfig.js","sourceRoot":"","sources":["../../../src/boundary/output/IConfig.ts"],"names":[],"mappings":""}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/boundary/output.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,qBAAqB,CAAC;AAE9C,YAAY,EAAE,MAAM,IAAI,OAAO,EAAE,CAAC"}
|
package/dist/boundary/output.js
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"output.js","sourceRoot":"","sources":["../../src/boundary/output.ts"],"names":[],"mappings":""}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"factory.d.ts","sourceRoot":"","sources":["../../src/factory/factory.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,EAAE,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,KAAK,MAAM,kBAAkB,CAAC;AACrC,OAAO,OAAO,MAAM,sBAAsB,CAAC;AAE3C,OAAO,EACL,OAAO,EACP,KAAK,EACL,OAAO,EACP,IAAI,GACL,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../../src/factory/factory.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,EAAE,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,KAAK,MAAM,kBAAkB,CAAC;AACrC,OAAO,OAAO,MAAM,sBAAsB,CAAC;AAE3C,OAAO,EACL,OAAO,EACP,KAAK,EACL,OAAO,EACP,IAAI,GACL,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"scopes.d.ts","sourceRoot":"","sources":["../../src/scopes/scopes.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,MAAM,iEAQF,CAAC;AAEX,eAAe,MAAM,CAAC;AACtB,MAAM,MAAM,KAAK,GAAG,OAAO,MAAM,CAAC,MAAM,CAAC,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"scopes.js","sourceRoot":"","sources":["../../src/scopes/scopes.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,GAAG;IACb,IAAI;IACJ,IAAI;IACJ,QAAQ;IACR,MAAM;IACN,MAAM;IACN,OAAO;IACP,KAAK;CACG,CAAC;AAEX,eAAe,MAAM,CAAC"}
|
package/src/boundary/input.ts
DELETED
package/src/boundary/output.ts
DELETED
package/src/factory/factory.ts
DELETED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
/package/src/boundary/output/{interface → config/interface}/option/language/ecma/IOLanguageEcma.d.ts
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
/package/src/boundary/output/{interface → config/interface}/option/processor/IOProcessor.d.ts
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|