@eslinted/core 0.6.0 → 0.7.0-rc.4
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/boundary/boundary.d.ts +6 -0
- package/dist/boundary/boundary.d.ts.map +1 -0
- package/dist/boundary/boundary.js +3 -0
- package/dist/boundary/boundary.js.map +1 -0
- package/dist/boundary/input/input.d.ts +5 -0
- package/dist/boundary/input/input.d.ts.map +1 -0
- package/dist/boundary/input/input.js +2 -0
- package/dist/boundary/input/input.js.map +1 -0
- package/dist/boundary/input/parsers/index.d.ts +5 -0
- package/dist/boundary/input/parsers/index.d.ts.map +1 -0
- package/dist/boundary/input/parsers/index.js +2 -0
- package/dist/boundary/input/parsers/index.js.map +1 -0
- package/dist/boundary/input/parsers/parsers.d.ts +7 -0
- package/dist/boundary/input/parsers/parsers.d.ts.map +1 -0
- package/dist/boundary/input/parsers/parsers.js +2 -0
- package/dist/boundary/input/parsers/parsers.js.map +1 -0
- package/dist/boundary/input/plugins/index.d.ts +32 -0
- package/dist/boundary/input/plugins/index.d.ts.map +1 -0
- package/dist/boundary/input/plugins/index.js +2 -0
- package/dist/boundary/input/plugins/index.js.map +1 -0
- package/dist/boundary/input/plugins/plugins.d.ts +6 -0
- package/dist/boundary/input/plugins/plugins.d.ts.map +1 -0
- package/dist/boundary/input/plugins/plugins.js +2 -0
- package/dist/boundary/input/plugins/plugins.js.map +1 -0
- package/dist/boundary/output/config/IConfig.d.ts +19 -0
- package/dist/boundary/output/config/IConfig.d.ts.map +1 -0
- package/dist/boundary/output/config/IConfig.js +2 -0
- package/dist/boundary/output/config/IConfig.js.map +1 -0
- package/dist/boundary/output/config/index.d.ts +19 -0
- package/dist/boundary/output/config/index.d.ts.map +1 -0
- package/dist/boundary/output/config/index.js +2 -0
- package/dist/boundary/output/config/index.js.map +1 -0
- package/dist/boundary/output/output.d.ts +3 -0
- package/dist/boundary/output/output.d.ts.map +1 -0
- package/dist/boundary/output/output.js +2 -0
- package/dist/boundary/output/output.js.map +1 -0
- package/dist/boundary/scopes/scopes.d.ts +4 -0
- package/dist/boundary/scopes/scopes.d.ts.map +1 -0
- package/dist/boundary/scopes/scopes.js +11 -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 +5 -0
- package/dist/factory/Factory.js.map +1 -0
- package/dist/factory/files/Files.d.ts +8 -0
- package/dist/factory/files/Files.d.ts.map +1 -0
- package/dist/factory/files/Files.js +15 -0
- package/dist/factory/files/Files.js.map +1 -0
- package/dist/factory/options/Options.d.ts +20 -0
- package/dist/factory/options/Options.d.ts.map +1 -0
- package/dist/factory/options/Options.js +17 -0
- package/dist/factory/options/Options.js.map +1 -0
- package/dist/factory/options/option/Option.d.ts +29 -0
- package/dist/factory/options/option/Option.d.ts.map +1 -0
- package/dist/factory/options/option/Option.js +26 -0
- package/dist/factory/options/option/Option.js.map +1 -0
- package/dist/factory/options/option/html/index.d.ts +7 -3
- package/dist/factory/options/option/html/index.d.ts.map +1 -1
- package/dist/factory/options/option/html/index.js +6 -12
- package/dist/factory/options/option/html/index.js.map +1 -1
- package/dist/factory/options/option/js/index.d.ts +7 -2
- package/dist/factory/options/option/js/index.d.ts.map +1 -1
- package/dist/factory/options/option/js/index.js +8 -15
- package/dist/factory/options/option/js/index.js.map +1 -1
- package/dist/factory/options/option/json/index.d.ts +7 -3
- package/dist/factory/options/option/json/index.d.ts.map +1 -1
- package/dist/factory/options/option/json/index.js +6 -12
- package/dist/factory/options/option/json/index.js.map +1 -1
- package/dist/factory/options/option/jsonc/index.d.ts +7 -3
- package/dist/factory/options/option/jsonc/index.d.ts.map +1 -1
- package/dist/factory/options/option/jsonc/index.js +6 -12
- package/dist/factory/options/option/jsonc/index.js.map +1 -1
- package/dist/factory/options/option/svelte/index.d.ts +22 -5
- package/dist/factory/options/option/svelte/index.d.ts.map +1 -1
- package/dist/factory/options/option/svelte/index.js +14 -21
- package/dist/factory/options/option/svelte/index.js.map +1 -1
- package/dist/factory/options/option/ts/index.d.ts +15 -4
- package/dist/factory/options/option/ts/index.d.ts.map +1 -1
- package/dist/factory/options/option/ts/index.js +12 -18
- package/dist/factory/options/option/ts/index.js.map +1 -1
- package/dist/factory/options/option/yml/index.d.ts +7 -3
- package/dist/factory/options/option/yml/index.d.ts.map +1 -1
- package/dist/factory/options/option/yml/index.js +6 -12
- package/dist/factory/options/option/yml/index.js.map +1 -1
- package/dist/factory/ruleset/Ruleset.d.ts +12 -0
- package/dist/factory/ruleset/Ruleset.d.ts.map +1 -0
- package/dist/factory/ruleset/Ruleset.js +27 -0
- package/dist/factory/ruleset/Ruleset.js.map +1 -0
- package/dist/factory/ruleset/rule/Rule.d.ts +6 -0
- package/dist/factory/ruleset/rule/Rule.d.ts.map +1 -0
- package/dist/factory/ruleset/rule/Rule.js +9 -0
- package/dist/factory/ruleset/rule/Rule.js.map +1 -0
- package/dist/index.d.ts +3 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +38 -26
- 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/parsers.ts +6 -0
- package/src/boundary/input/plugins/plugins.ts +7 -0
- package/src/{config/index.ts → boundary/output/config/IConfig.ts} +3 -4
- package/src/boundary/output/config/interface/option/IOption.d.ts +20 -0
- package/src/boundary/output/config/interface/option/language/IOLanguage.d.ts +18 -0
- package/src/boundary/output/config/interface/option/language/ecma/IOLanguageEcma.d.ts +1 -0
- package/src/boundary/output/config/interface/option/language/globals/IOLanguageGlobals.d.ts +1 -0
- package/src/boundary/output/config/interface/option/language/source/IOLanguageSource.d.ts +3 -0
- package/src/boundary/output/config/interface/option/linter/IOLinter.d.ts +4 -0
- package/src/boundary/output/config/interface/option/name/IOName.d.ts +1 -0
- package/src/boundary/output/config/interface/option/plugins/IOPlugins.d.ts +1 -0
- package/src/boundary/output/config/interface/option/processor/IOProcessor.d.ts +1 -0
- package/src/boundary/output/output.ts +3 -0
- package/src/factory/Factory.ts +13 -0
- package/src/factory/files/Files.ts +15 -0
- package/src/factory/options/{index.ts → Options.ts} +2 -2
- package/src/factory/options/option/Option.ts +58 -0
- package/src/factory/options/option/html/index.ts +10 -23
- package/src/factory/options/option/js/index.ts +9 -20
- package/src/factory/options/option/json/index.ts +10 -23
- package/src/factory/options/option/jsonc/index.ts +10 -23
- package/src/factory/options/option/svelte/index.ts +23 -34
- package/src/factory/options/option/ts/index.ts +20 -29
- package/src/factory/options/option/yml/index.ts +10 -23
- package/src/factory/ruleset/{index.ts → Ruleset.ts} +1 -1
- package/src/index.ts +62 -72
- package/types/project/OmitLast.d.ts +1 -0
- package/src/config/files/IFiles.d.ts +0 -1
- package/src/config/option/IOption.d.ts +0 -25
- package/src/config/option/language/IOLanguage.d.ts +0 -15
- package/src/config/option/language/ecma/IOLanguageEcma.d.ts +0 -19
- package/src/config/option/language/globals/IOLanguageGlobals.d.ts +0 -3
- package/src/config/option/language/parser/IOLanguageParser.d.ts +0 -3
- package/src/config/option/language/parserOptions/IOLanguageParserOptions.d.ts +0 -5
- package/src/config/option/language/source/IOLanguageSource.d.ts +0 -12
- package/src/config/option/linter/IOLinter.d.ts +0 -30
- package/src/config/option/name/IOName.d.ts +0 -3
- package/src/config/option/plugins/IOPlugins.d.ts +0 -3
- package/src/config/option/processor/IOProcessor.d.ts +0 -3
- package/src/config/rules/IRules.d.ts +0 -1
- package/src/factory/files/index.ts +0 -20
- package/src/factory/index.ts +0 -12
- package/src/factory/options/option/index.ts +0 -27
- package/src/module/boundary/index.ts +0 -3
- package/src/module/boundary/parsers/index.ts +0 -12
- package/src/module/boundary/plugins/index.ts +0 -20
- package/src/module/index.ts +0 -9
- /package/src/{config/rules/rule → boundary/output/config/interface/rules}/IRule.d.ts +0 -0
- /package/src/{config/rules/rule → boundary/output/config/interface/rules}/state/RuleSeverity.d.ts +0 -0
- /package/src/{module/scopes/index.ts → boundary/scopes/scopes.ts} +0 -0
- /package/src/factory/ruleset/rule/{index.ts → Rule.ts} +0 -0
- /package/types/{literal → typioca/literal}/number/base32.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/base64.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/binary.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/decimal.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/hex.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/octal.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/quatral.d.ts +0 -0
- /package/types/{literal → typioca/literal}/number/ternary.d.ts +0 -0
- /package/types/{literal → typioca/literal}/string/base64char.d.ts +0 -0
- /package/types/{literal → typioca/literal}/string/digit.d.ts +0 -0
- /package/types/{literal → typioca/literal}/string/hexchar.d.ts +0 -0
- /package/types/{literal → typioca/literal}/string/letter.d.ts +0 -0
- /package/types/{safe → typioca/safe}/Safe.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/finite/Finite.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/finite.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/fint.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/int/Int.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/int.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/numberful.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/polarity/Negative.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/polarity/Positive.d.ts +0 -0
- /package/types/{safe → typioca/safe}/numbers/polarity/pole/Pole.d.ts +0 -0
- /package/types/{safe → typioca/safe}/primitive.d.ts +0 -0
- /package/types/{safe → typioca/safe}/strings/char.d.ts +0 -0
- /package/types/{safe → typioca/safe}/strings/length/PropLength.d.ts +0 -0
- /package/types/{safe → typioca/safe}/strings/stringful.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/Particord.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/Property.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/Recordful.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/Table.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/properties/Field.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/properties/Flag.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/properties/Limit.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/properties/List.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/properties/Listish.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/properties/Scalar.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/tables/FieldTable.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/tables/FlagTable.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/tables/ListTable.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/tables/ListishTable.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/construct/tables/ScalarTable.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/identity/Interface.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/identity/Keys.d.ts +0 -0
- /package/types/{utility → typioca/utility}/interface/transform/Unrequire.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/construct/ArrayN.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/construct/Tuple.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/construct/arrays/Arrays.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/construct/tuples/Tuples.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/identity/DyadType.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/identity/MonadType.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/identity/TriadType.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/identity/array/ArrayType.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/identity/array/length/ArrayLength.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/transform/Join.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/transform/Unflat.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/transform/stringarray/Chain.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/transform/stringarray/PathN.d.ts +0 -0
- /package/types/{utility → typioca/utility}/iterable/transform/stringarray/stringify/Stringify.d.ts +0 -0
- /package/types/{utility → typioca/utility}/length/Length.d.ts +0 -0
- /package/types/{utility → typioca/utility}/null/null.d.ts +0 -0
- /package/types/{utility → typioca/utility}/null/nullable.d.ts +0 -0
- /package/types/{utility → typioca/utility}/primitive/Primeval.d.ts +0 -0
- /package/types/{utility → typioca/utility}/primitive/boolean/True.d.ts +0 -0
- /package/types/{utility → typioca/utility}/primitive/number/Numbered.d.ts +0 -0
- /package/types/{utility → typioca/utility}/primitive/string/literal.d.ts +0 -0
- /package/types/{utility → typioca/utility}/primitive/string/literalful.d.ts +0 -0
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/jsonc/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/jsonc/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,MAAM,CAC7C,OAAO,EACP,OAAO,EACP,KAAK,EACL,IAAI,EACJ,CAAC,CACF;IACC,SAAgB,IAAI,iBAAiB;IACrC,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAIzB;CACF"}
|
@@ -1,16 +1,10 @@
|
|
1
|
-
import Option from "../
|
1
|
+
import Option from "../Option.js";
|
2
2
|
export default class JsoncOption extends Option {
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
linterOptions: {
|
9
|
-
noInlineConfig: true,
|
10
|
-
reportUnusedDisableDirectives: "error",
|
11
|
-
},
|
12
|
-
languageOptions: { parser },
|
13
|
-
});
|
3
|
+
name = "scope:jsonc";
|
4
|
+
processor = {};
|
5
|
+
get languageOptions() {
|
6
|
+
const [parser] = this.parser;
|
7
|
+
return { parser };
|
14
8
|
}
|
15
9
|
}
|
16
10
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/jsonc/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/jsonc/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,MAMxC;IACiB,IAAI,GAAG,aAAa,CAAC;IACrB,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;QAE7B,OAAO,EAAE,MAAM,EAAW,CAAC;IAC7B,CAAC;CACF"}
|
@@ -1,10 +1,27 @@
|
|
1
|
-
import Option from "../
|
1
|
+
import Option from "../Option.js";
|
2
2
|
import type TsOption from "../ts/index.js";
|
3
|
-
export default class SvelteOption extends Option<"svelte", "svelte" | keyof TsOption["
|
3
|
+
export default class SvelteOption extends Option<"svelte", "svelte" | keyof TsOption["option"]["plugins"], true, TsOption["option"]["languageOptions"]["parserOptions"] & {
|
4
4
|
parser: unknown;
|
5
5
|
} & {
|
6
|
-
extraFileExtensions: [".svelte"];
|
7
|
-
}, never,
|
8
|
-
|
6
|
+
extraFileExtensions: readonly [".svelte"];
|
7
|
+
}, 2, never, {
|
8
|
+
processor: "svelte/svelte";
|
9
|
+
}> {
|
10
|
+
readonly name = "scope:svelte";
|
11
|
+
readonly processor: {
|
12
|
+
readonly processor: "svelte/svelte";
|
13
|
+
};
|
14
|
+
get languageOptions(): {
|
15
|
+
readonly ecmaVersion: "latest";
|
16
|
+
readonly sourceType: "module";
|
17
|
+
readonly parser: unknown;
|
18
|
+
readonly parserOptions: {
|
19
|
+
readonly ecmaVersion: "latest";
|
20
|
+
readonly sourceType: "module";
|
21
|
+
readonly project: "tsconfig.json";
|
22
|
+
readonly extraFileExtensions: readonly [".svelte"];
|
23
|
+
readonly parser: unknown;
|
24
|
+
};
|
25
|
+
};
|
9
26
|
}
|
10
27
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/svelte/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/svelte/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAClC,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAC;AAE3C,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,MAAM,CAC9C,QAAQ,EACR,QAAQ,GAAG,MAAM,QAAQ,CAAC,QAAQ,CAAC,CAAC,SAAS,CAAC,EAC9C,IAAI,EACF,QAAQ,CAAC,QAAQ,CAAC,CAAC,iBAAiB,CAAC,CAAC,eAAe,CAAC,GACtD;IAAE,MAAM,EAAE,OAAO,CAAA;CAAE,GACnB;IAAE,mBAAmB,EAAE,SAAS,CAAC,SAAS,CAAC,CAAA;CAAE,EAC/C,CAAC,EACD,KAAK,EACL;IAAE,SAAS,EAAE,eAAe,CAAA;CAAE,CAC/B;IACC,SAAgB,IAAI,kBAAkB;IACtC,SAAgB,SAAS;;MAA2C;IAEpE,IAAW,eAAe;;;;;;;;;;;MAezB;CACF"}
|
@@ -1,28 +1,21 @@
|
|
1
|
-
import Option from "../
|
1
|
+
import Option from "../Option.js";
|
2
2
|
export default class SvelteOption extends Option {
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
},
|
13
|
-
languageOptions: {
|
3
|
+
name = "scope:svelte";
|
4
|
+
processor = { processor: "svelte/svelte" };
|
5
|
+
get languageOptions() {
|
6
|
+
const [parser, tsParser] = this.parser;
|
7
|
+
return {
|
8
|
+
ecmaVersion: "latest",
|
9
|
+
sourceType: "module",
|
10
|
+
parser,
|
11
|
+
parserOptions: {
|
14
12
|
ecmaVersion: "latest",
|
15
13
|
sourceType: "module",
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
sourceType: "module",
|
20
|
-
project: "tsconfig.json",
|
21
|
-
extraFileExtensions: [".svelte"],
|
22
|
-
parser: tsParser,
|
23
|
-
},
|
14
|
+
project: "tsconfig.json",
|
15
|
+
extraFileExtensions: [".svelte"],
|
16
|
+
parser: tsParser,
|
24
17
|
},
|
25
|
-
}
|
18
|
+
};
|
26
19
|
}
|
27
20
|
}
|
28
21
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/svelte/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/svelte/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAGlC,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,MAUzC;IACiB,IAAI,GAAG,cAAc,CAAC;IACtB,SAAS,GAAG,EAAE,SAAS,EAAE,eAAe,EAAW,CAAC;IAEpE,IAAW,eAAe;QACxB,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;QAEvC,OAAO;YACL,WAAW,EAAE,QAAQ;YACrB,UAAU,EAAE,QAAQ;YACpB,MAAM;YACN,aAAa,EAAE;gBACb,WAAW,EAAE,QAAQ;gBACrB,UAAU,EAAE,QAAQ;gBACpB,OAAO,EAAE,eAAe;gBACxB,mBAAmB,EAAE,CAAC,SAAS,CAAU;gBACzC,MAAM,EAAE,QAAQ;aACjB;SACO,CAAC;IACb,CAAC;CACF"}
|
@@ -1,8 +1,19 @@
|
|
1
|
-
import Option from "../
|
1
|
+
import Option from "../Option.js";
|
2
2
|
import type JsOption from "../js/index.js";
|
3
|
-
export default class TsOption extends Option<"ts", "@typescript-eslint" | keyof JsOption["
|
3
|
+
export default class TsOption extends Option<"ts", "@typescript-eslint" | keyof JsOption["option"]["plugins"], true, JsOption["option"]["languageOptions"] & {
|
4
4
|
project: "tsconfig.json";
|
5
|
-
}> {
|
6
|
-
|
5
|
+
}, 1> {
|
6
|
+
readonly name = "scope:ts";
|
7
|
+
readonly processor: {};
|
8
|
+
get languageOptions(): {
|
9
|
+
readonly ecmaVersion: "latest";
|
10
|
+
readonly sourceType: "module";
|
11
|
+
readonly parser: unknown;
|
12
|
+
readonly parserOptions: {
|
13
|
+
readonly ecmaVersion: "latest";
|
14
|
+
readonly sourceType: "module";
|
15
|
+
readonly project: "tsconfig.json";
|
16
|
+
};
|
17
|
+
};
|
7
18
|
}
|
8
19
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/ts/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/ts/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAClC,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAC;AAE3C,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAAM,CAC1C,IAAI,EACJ,oBAAoB,GAAG,MAAM,QAAQ,CAAC,QAAQ,CAAC,CAAC,SAAS,CAAC,EAC1D,IAAI,EACF,QAAQ,CAAC,QAAQ,CAAC,CAAC,iBAAiB,CAAC,GACrC;IAAE,OAAO,EAAE,eAAe,CAAA;CAAE,EAC9B,CAAC,CACF;IACC,SAAgB,IAAI,cAAc;IAClC,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;;;;;;;;MAazB;CACF"}
|
@@ -1,25 +1,19 @@
|
|
1
|
-
import Option from "../
|
1
|
+
import Option from "../Option.js";
|
2
2
|
export default class TsOption extends Option {
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
languageOptions: {
|
3
|
+
name = "scope:ts";
|
4
|
+
processor = {};
|
5
|
+
get languageOptions() {
|
6
|
+
const [parser] = this.parser;
|
7
|
+
return {
|
8
|
+
ecmaVersion: "latest",
|
9
|
+
sourceType: "module",
|
10
|
+
parser,
|
11
|
+
parserOptions: {
|
13
12
|
ecmaVersion: "latest",
|
14
13
|
sourceType: "module",
|
15
|
-
|
16
|
-
parserOptions: {
|
17
|
-
ecmaVersion: "latest",
|
18
|
-
sourceType: "module",
|
19
|
-
project: "tsconfig.json",
|
20
|
-
},
|
14
|
+
project: "tsconfig.json",
|
21
15
|
},
|
22
|
-
}
|
16
|
+
};
|
23
17
|
}
|
24
18
|
}
|
25
19
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/ts/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/ts/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAGlC,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAOrC;IACiB,IAAI,GAAG,UAAU,CAAC;IAClB,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;QAE7B,OAAO;YACL,WAAW,EAAE,QAAQ;YACrB,UAAU,EAAE,QAAQ;YACpB,MAAM;YACN,aAAa,EAAE;gBACb,WAAW,EAAE,QAAQ;gBACrB,UAAU,EAAE,QAAQ;gBACpB,OAAO,EAAE,eAAe;aACzB;SACO,CAAC;IACb,CAAC;CACF"}
|
@@ -1,5 +1,9 @@
|
|
1
|
-
import Option from "../
|
2
|
-
export default class YmlOption extends Option<"yml", "yml",
|
3
|
-
|
1
|
+
import Option from "../Option.js";
|
2
|
+
export default class YmlOption extends Option<"yml", "yml", false, true, 1> {
|
3
|
+
readonly name = "scope:yml";
|
4
|
+
readonly processor: {};
|
5
|
+
get languageOptions(): {
|
6
|
+
readonly parser: unknown;
|
7
|
+
};
|
4
8
|
}
|
5
9
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/yml/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/yml/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,MAAM,CAC3C,KAAK,EACL,KAAK,EACL,KAAK,EACL,IAAI,EACJ,CAAC,CACF;IACC,SAAgB,IAAI,eAAe;IACnC,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAIzB;CACF"}
|
@@ -1,16 +1,10 @@
|
|
1
|
-
import Option from "../
|
1
|
+
import Option from "../Option.js";
|
2
2
|
export default class YmlOption extends Option {
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
linterOptions: {
|
9
|
-
noInlineConfig: true,
|
10
|
-
reportUnusedDisableDirectives: "error",
|
11
|
-
},
|
12
|
-
languageOptions: { parser },
|
13
|
-
});
|
3
|
+
name = "scope:yml";
|
4
|
+
processor = {};
|
5
|
+
get languageOptions() {
|
6
|
+
const [parser] = this.parser;
|
7
|
+
return { parser };
|
14
8
|
}
|
15
9
|
}
|
16
10
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/yml/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/yml/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,MAMtC;IACiB,IAAI,GAAG,WAAW,CAAC;IACnB,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;QAE7B,OAAO,EAAE,MAAM,EAAW,CAAC;IAC7B,CAAC;CACF"}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
import Rule from "./rule/Rule.js";
|
2
|
+
export { Rule };
|
3
|
+
export default class Ruleset<Language extends string> {
|
4
|
+
readonly language: literalful<Language>;
|
5
|
+
readonly ruleset: readonly Rule[];
|
6
|
+
readonly overrides: Rule[];
|
7
|
+
constructor(language: literalful<Language>, ...ruleset: readonly Rule[]);
|
8
|
+
get id(): `ruleset:${literalful<Language>}`;
|
9
|
+
get flat(): IRule[];
|
10
|
+
override(...overrides: (undefined | IRule)[]): this;
|
11
|
+
}
|
12
|
+
//# sourceMappingURL=Ruleset.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Ruleset.d.ts","sourceRoot":"","sources":["../../../src/factory/ruleset/Ruleset.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,gBAAgB,CAAC;AAElC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO,CAAC,QAAQ,SAAS,MAAM;aAKhC,QAAQ,EAAE,UAAU,CAAC,QAAQ,CAAC;IAJhD,SAAgB,OAAO,EAAE,SAAS,IAAI,EAAE,CAAC;IACzC,SAAgB,SAAS,EAAE,IAAI,EAAE,CAAM;gBAGrB,QAAQ,EAAE,UAAU,CAAC,QAAQ,CAAC,EAC9C,GAAG,OAAO,EAAE,SAAS,IAAI,EAAE;IAK7B,IAAW,EAAE,sCAEZ;IAED,IAAW,IAAI,YAKd;IAEM,QAAQ,CAAC,GAAG,SAAS,EAAE,CAAC,SAAS,GAAG,KAAK,CAAC,EAAE;CAcpD"}
|
@@ -0,0 +1,27 @@
|
|
1
|
+
import Rule from "./rule/Rule.js";
|
2
|
+
export { Rule };
|
3
|
+
export default class Ruleset {
|
4
|
+
language;
|
5
|
+
ruleset;
|
6
|
+
overrides = [];
|
7
|
+
constructor(language, ...ruleset) {
|
8
|
+
this.language = language;
|
9
|
+
this.ruleset = [...ruleset];
|
10
|
+
}
|
11
|
+
get id() {
|
12
|
+
return `ruleset:${this.language}`;
|
13
|
+
}
|
14
|
+
get flat() {
|
15
|
+
return [
|
16
|
+
...this.ruleset.map(rules => rules.rules),
|
17
|
+
...this.overrides.map(rules => rules.rules),
|
18
|
+
];
|
19
|
+
}
|
20
|
+
override(...overrides) {
|
21
|
+
this.overrides.push(...overrides
|
22
|
+
.filter(override => typeof override !== "undefined")
|
23
|
+
.map(override => new Rule("override", override)));
|
24
|
+
return this;
|
25
|
+
}
|
26
|
+
}
|
27
|
+
//# sourceMappingURL=Ruleset.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Ruleset.js","sourceRoot":"","sources":["../../../src/factory/ruleset/Ruleset.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,gBAAgB,CAAC;AAElC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO;IAKR;IAJF,OAAO,CAAkB;IACzB,SAAS,GAAW,EAAE,CAAC;IAEvC,YACkB,QAA8B,EAC9C,GAAG,OAAwB;QADX,aAAQ,GAAR,QAAQ,CAAsB;QAG9C,IAAI,CAAC,OAAO,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC;IAC9B,CAAC;IAED,IAAW,EAAE;QACX,OAAO,WAAW,IAAI,CAAC,QAAQ,EAAW,CAAC;IAC7C,CAAC;IAED,IAAW,IAAI;QACb,OAAO;YACL,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC;YACzC,GAAG,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC;SAC5C,CAAC;IACJ,CAAC;IAEM,QAAQ,CAAC,GAAG,SAAgC;QACjD,IAAI,CAAC,SAAS,CAAC,IAAI,CACjB,GAAG,SAAS;aACT,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,OAAO,QAAQ,KAAK,WAAW,CAAC;aACnD,GAAG,CACF,QAAQ,CAAC,EAAE,CAAC,IAAI,IAAI,CAClB,UAAU,EACV,QAAQ,CACT,CACF,CACJ,CAAC;QAEF,OAAO,IAAI,CAAC;IACd,CAAC;CACF"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Rule.d.ts","sourceRoot":"","sources":["../../../../src/factory/ruleset/rule/Rule.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO;aAEM,EAAE,EAAE,MAAM;aACV,KAAK,EAAE,KAAK;gBADZ,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,KAAK;CAE/B"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Rule.js","sourceRoot":"","sources":["../../../../src/factory/ruleset/rule/Rule.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO;IAEM;IACA;IAFlB,YACkB,EAAU,EACV,KAAY;QADZ,OAAE,GAAF,EAAE,CAAQ;QACV,UAAK,GAAL,KAAK,CAAO;IAC3B,CAAC;CACL"}
|
package/dist/index.d.ts
CHANGED
@@ -1,8 +1,7 @@
|
|
1
|
-
import {
|
2
|
-
import
|
3
|
-
import type Config from "./config/index.js";
|
4
|
-
export { Ruleset, Rule };
|
1
|
+
import type { Scope, Plugins, Parsers, Config } from "./boundary/boundary.js";
|
2
|
+
import { Ruleset, Rule } from "./factory/Factory.js";
|
5
3
|
export type { Scope };
|
4
|
+
export { Ruleset, Rule };
|
6
5
|
export default function (plugins: Plugins, parsers: Parsers, base: Record<Scope, string[]>, includes: Particord<Scope, string[]>, rulesets: {
|
7
6
|
[S in Scope]: Ruleset<S>;
|
8
7
|
}, overrides: Particord<Scope, IRule>): Config[];
|
package/dist/index.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,KAAK,EACL,OAAO,EACP,OAAO,EACP,MAAM,EACP,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAGL,OAAO,EACP,IAAI,EACL,MAAM,sBAAsB,CAAC;AAE9B,YAAY,EAAE,KAAK,EAAE,CAAC;AACtB,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;AACzB,MAAM,CAAC,OAAO,WACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC,EAC7B,QAAQ,EAAE,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC,EACpC,QAAQ,EAAE;KAAG,CAAC,IAAI,KAAK,GAAG,OAAO,CAAC,CAAC,CAAC;CAAE,EACtC,SAAS,EAAE,SAAS,CAAC,KAAK,EAAE,KAAK,CAAC,GACjC,MAAM,EAAE,CAgGV"}
|
package/dist/index.js
CHANGED
@@ -1,41 +1,53 @@
|
|
1
|
-
import scopes from "./
|
2
|
-
import {
|
1
|
+
import scopes from "./boundary/boundary.js";
|
2
|
+
import { Options, Files, Ruleset, Rule, } from "./factory/Factory.js";
|
3
3
|
export { Ruleset, Rule };
|
4
4
|
export default function (plugins, parsers, base, includes, rulesets, overrides) {
|
5
5
|
try {
|
6
|
+
const files = new Files(base, includes), imports = {
|
7
|
+
js: [plugins.js, []],
|
8
|
+
ts: [plugins.ts, [parsers.ts]],
|
9
|
+
svelte: [
|
10
|
+
plugins.svelte,
|
11
|
+
[parsers.svelte, parsers.ts],
|
12
|
+
],
|
13
|
+
html: [plugins.html, [parsers.html]],
|
14
|
+
json: [plugins.json, [parsers.json]],
|
15
|
+
jsonc: [plugins.jsonc, [parsers.jsonc]],
|
16
|
+
yml: [plugins.yml, [parsers.yml]],
|
17
|
+
};
|
6
18
|
for (const scope of scopes)
|
7
19
|
rulesets[scope].override(overrides[scope]);
|
8
|
-
const
|
9
|
-
js: new
|
10
|
-
.js(
|
11
|
-
.
|
12
|
-
ts: new
|
13
|
-
.ts(
|
14
|
-
.
|
15
|
-
svelte: new
|
16
|
-
.svelte(
|
17
|
-
.
|
18
|
-
html: new
|
19
|
-
.html(
|
20
|
-
.
|
21
|
-
json: new
|
22
|
-
.json(
|
23
|
-
.
|
24
|
-
jsonc: new
|
25
|
-
.jsonc(
|
26
|
-
.
|
27
|
-
yml: new
|
28
|
-
.yml(
|
29
|
-
.
|
20
|
+
const options = {
|
21
|
+
js: new Options
|
22
|
+
.js(files.files("js"), ...imports.js)
|
23
|
+
.option,
|
24
|
+
ts: new Options
|
25
|
+
.ts(files.files("ts"), ...imports.ts)
|
26
|
+
.option,
|
27
|
+
svelte: new Options
|
28
|
+
.svelte(files.files("svelte"), ...imports.svelte)
|
29
|
+
.option,
|
30
|
+
html: new Options
|
31
|
+
.html(files.files("html"), ...imports.html)
|
32
|
+
.option,
|
33
|
+
json: new Options
|
34
|
+
.json(files.files("json"), ...imports.json)
|
35
|
+
.option,
|
36
|
+
jsonc: new Options
|
37
|
+
.jsonc(files.files("jsonc"), ...imports.jsonc)
|
38
|
+
.option,
|
39
|
+
yml: new Options
|
40
|
+
.yml(files.files("yml"), ...imports.yml)
|
41
|
+
.option,
|
30
42
|
};
|
31
43
|
return scopes
|
32
|
-
.map(scope =>
|
44
|
+
.map(scope => options[scope].files.length > 0
|
33
45
|
? rulesets[scope]
|
34
46
|
.flat
|
35
47
|
.map(rules => {
|
36
48
|
return {
|
37
49
|
rules,
|
38
|
-
...
|
50
|
+
...options[scope],
|
39
51
|
};
|
40
52
|
})
|
41
53
|
: [])
|
package/dist/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"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"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@eslinted/core",
|
3
|
-
"version": "0.
|
3
|
+
"version": "0.7.0-rc.4",
|
4
4
|
"description": "",
|
5
5
|
"keywords": [],
|
6
6
|
"license": "MIT",
|
@@ -33,7 +33,7 @@
|
|
33
33
|
"dependencies": {},
|
34
34
|
"devDependencies": {
|
35
35
|
"eslint": "~8.57.0",
|
36
|
-
"linted": "~15.3.
|
36
|
+
"linted": "~15.3.2",
|
37
37
|
"npm-run-all": "^4.1.5",
|
38
38
|
"typescript": "^5.5.3"
|
39
39
|
},
|
@@ -1,7 +1,7 @@
|
|
1
|
-
export default interface
|
1
|
+
export default interface IConfig {
|
2
|
+
name: `scope:${string}`;
|
2
3
|
rules: IRule;
|
3
4
|
files: readonly string[];
|
4
|
-
name: `linted/scope:${string}`;
|
5
5
|
linterOptions: {
|
6
6
|
noInlineConfig: true;
|
7
7
|
reportUnusedDisableDirectives: "error";
|
@@ -9,8 +9,7 @@ export default interface Config {
|
|
9
9
|
languageOptions: {
|
10
10
|
sourceType?:
|
11
11
|
| "module"
|
12
|
-
| "script"
|
13
|
-
;
|
12
|
+
| "script";
|
14
13
|
ecmaVersion?: "latest";
|
15
14
|
globals?: Record<string, true>;
|
16
15
|
parser?: unknown;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
declare type IOption<
|
2
|
+
Name extends string,
|
3
|
+
PluginId extends string,
|
4
|
+
IsEcma extends boolean,
|
5
|
+
ParserOptions extends object | boolean,
|
6
|
+
GlobalTypes extends string,
|
7
|
+
Processor extends object,
|
8
|
+
> =
|
9
|
+
{
|
10
|
+
name: IOName<Name>;
|
11
|
+
files: readonly string[];
|
12
|
+
linterOptions: IOLinter;
|
13
|
+
languageOptions: IOLanguage<
|
14
|
+
IsEcma,
|
15
|
+
ParserOptions,
|
16
|
+
GlobalTypes
|
17
|
+
>;
|
18
|
+
}
|
19
|
+
& (IOPlugins<PluginId> extends never ? object : { plugins: IOPlugins<PluginId> })
|
20
|
+
& (Interface<Processor> extends never ? object : Interface<Processor> extends { "interface": string } ? Interface<Processor> : object);
|
@@ -0,0 +1,18 @@
|
|
1
|
+
declare type IOLanguage<
|
2
|
+
IsEcma extends boolean,
|
3
|
+
ParserOptions extends object | boolean,
|
4
|
+
GlobalTypes extends string,
|
5
|
+
> =
|
6
|
+
& (True<IsEcma> extends never ? object : { ecmaVersion: IOLanguageEcma; sourceType: IOLanguageSource })
|
7
|
+
& (literalful<GlobalTypes> extends never ? object : { globals: IOLanguageGlobals<GlobalTypes> })
|
8
|
+
& (
|
9
|
+
ParserOptions extends boolean
|
10
|
+
? True<ParserOptions> extends never
|
11
|
+
? object
|
12
|
+
: { parser: unknown }
|
13
|
+
: ParserOptions extends object
|
14
|
+
? Interface<ParserOptions> extends never
|
15
|
+
? object
|
16
|
+
: { parser: unknown; parserOptions: ParserOptions }
|
17
|
+
: object
|
18
|
+
);
|
@@ -0,0 +1 @@
|
|
1
|
+
declare type IOLanguageEcma = "latest";
|
@@ -0,0 +1 @@
|
|
1
|
+
declare type IOLanguageGlobals<GlobalTypes extends string> = Record<GlobalTypes, true>;
|
@@ -0,0 +1 @@
|
|
1
|
+
declare type IOName<Name extends string> = literalful<Name>;
|
@@ -0,0 +1 @@
|
|
1
|
+
declare type IOPlugins<PluginId extends string> = Record<literalful<PluginId>, { configs: unknown }>;
|
@@ -0,0 +1 @@
|
|
1
|
+
declare type IOProcessor<ProcessorId extends string> = literalful<ProcessorId>;
|