@eslinted/core 0.9.0-rc.4 → 0.9.0-rc.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (117) hide show
  1. package/dist/boundary/input/{parsers/parsers.d.ts → parsers.d.ts} +2 -2
  2. package/dist/boundary/input/parsers.d.ts.map +1 -0
  3. package/dist/boundary/input/parsers.js.map +1 -0
  4. package/dist/boundary/input/plugins.d.ts +7 -0
  5. package/dist/boundary/input/plugins.d.ts.map +1 -0
  6. package/dist/boundary/input/plugins.js.map +1 -0
  7. package/dist/boundary/input.d.ts +8 -0
  8. package/dist/boundary/input.d.ts.map +1 -0
  9. package/dist/boundary/{input/input.js.map → input.js.map} +1 -1
  10. package/dist/boundary/output/IConfig.d.ts.map +1 -0
  11. package/dist/boundary/output/IConfig.js.map +1 -0
  12. package/dist/boundary/output.d.ts +3 -0
  13. package/dist/boundary/output.d.ts.map +1 -0
  14. package/dist/boundary/{output/output.js.map → output.js.map} +1 -1
  15. package/dist/factory/{Factory.d.ts → factory.d.ts} +1 -1
  16. package/dist/factory/{Factory.js → factory.js} +1 -1
  17. package/dist/factory/files/Files.d.ts.map +1 -1
  18. package/dist/factory/files/Files.js +9 -4
  19. package/dist/factory/files/Files.js.map +1 -1
  20. package/dist/factory/options/option/Option.d.ts +6 -20
  21. package/dist/factory/options/option/Option.d.ts.map +1 -1
  22. package/dist/factory/options/option/Option.js +33 -23
  23. package/dist/factory/options/option/Option.js.map +1 -1
  24. package/dist/factory/options/option/html/index.d.ts.map +1 -1
  25. package/dist/factory/options/option/html/index.js +7 -2
  26. package/dist/factory/options/option/html/index.js.map +1 -1
  27. package/dist/factory/options/option/js/index.d.ts.map +1 -1
  28. package/dist/factory/options/option/js/index.js +9 -4
  29. package/dist/factory/options/option/js/index.js.map +1 -1
  30. package/dist/factory/options/option/json/index.d.ts.map +1 -1
  31. package/dist/factory/options/option/json/index.js +7 -2
  32. package/dist/factory/options/option/json/index.js.map +1 -1
  33. package/dist/factory/options/option/jsonc/index.d.ts.map +1 -1
  34. package/dist/factory/options/option/jsonc/index.js +7 -2
  35. package/dist/factory/options/option/jsonc/index.js.map +1 -1
  36. package/dist/factory/options/option/svelte/index.d.ts.map +1 -1
  37. package/dist/factory/options/option/svelte/index.js +16 -11
  38. package/dist/factory/options/option/svelte/index.js.map +1 -1
  39. package/dist/factory/options/option/ts/index.d.ts.map +1 -1
  40. package/dist/factory/options/option/ts/index.js +14 -9
  41. package/dist/factory/options/option/ts/index.js.map +1 -1
  42. package/dist/factory/options/option/yml/index.d.ts.map +1 -1
  43. package/dist/factory/options/option/yml/index.js +7 -2
  44. package/dist/factory/options/option/yml/index.js.map +1 -1
  45. package/dist/factory/options/{Options.d.ts → options.d.ts} +1 -1
  46. package/dist/factory/options/{Options.d.ts.map → options.d.ts.map} +1 -1
  47. package/dist/factory/options/{Options.js → options.js} +1 -1
  48. package/dist/factory/options/{Options.js.map → options.js.map} +1 -1
  49. package/dist/factory/ruleset/Ruleset.d.ts.map +1 -1
  50. package/dist/factory/ruleset/Ruleset.js +31 -11
  51. package/dist/factory/ruleset/Ruleset.js.map +1 -1
  52. package/dist/index.d.ts +5 -4
  53. package/dist/index.d.ts.map +1 -1
  54. package/dist/index.js +1 -1
  55. package/dist/index.js.map +1 -1
  56. package/package.json +2 -2
  57. package/src/boundary/input/{parsers/parsers.ts → parsers.ts} +2 -2
  58. package/src/boundary/input/{plugins/plugins.ts → plugins.ts} +2 -2
  59. package/src/boundary/{input/input.ts → input.ts} +2 -2
  60. package/src/boundary/output.ts +3 -0
  61. package/src/factory/factory.ts +1 -1
  62. package/src/factory/files/Files.ts +12 -4
  63. package/src/factory/options/option/Option.ts +69 -49
  64. package/src/factory/options/option/html/index.ts +10 -2
  65. package/src/factory/options/option/js/index.ts +12 -4
  66. package/src/factory/options/option/json/index.ts +10 -2
  67. package/src/factory/options/option/jsonc/index.ts +10 -2
  68. package/src/factory/options/option/svelte/index.ts +19 -11
  69. package/src/factory/options/option/ts/index.ts +17 -9
  70. package/src/factory/options/option/yml/index.ts +10 -2
  71. package/src/factory/ruleset/Ruleset.ts +46 -14
  72. package/src/index.ts +7 -6
  73. package/dist/boundary/boundary.d.ts +0 -11
  74. package/dist/boundary/boundary.d.ts.map +0 -1
  75. package/dist/boundary/boundary.js +0 -2
  76. package/dist/boundary/boundary.js.map +0 -1
  77. package/dist/boundary/input/input.d.ts +0 -8
  78. package/dist/boundary/input/input.d.ts.map +0 -1
  79. package/dist/boundary/input/parsers/parsers.d.ts.map +0 -1
  80. package/dist/boundary/input/parsers/parsers.js.map +0 -1
  81. package/dist/boundary/input/plugins/plugins.d.ts +0 -7
  82. package/dist/boundary/input/plugins/plugins.d.ts.map +0 -1
  83. package/dist/boundary/input/plugins/plugins.js.map +0 -1
  84. package/dist/boundary/output/config/IConfig.d.ts.map +0 -1
  85. package/dist/boundary/output/config/IConfig.js.map +0 -1
  86. package/dist/boundary/output/output.d.ts +0 -3
  87. package/dist/boundary/output/output.d.ts.map +0 -1
  88. package/dist/boundary/scopes/scopes.d.ts +0 -4
  89. package/dist/boundary/scopes/scopes.d.ts.map +0 -1
  90. package/dist/boundary/scopes/scopes.js +0 -11
  91. package/dist/boundary/scopes/scopes.js.map +0 -1
  92. package/dist/factory/_factory.d.ts +0 -5
  93. package/dist/factory/_factory.d.ts.map +0 -1
  94. package/dist/factory/_factory.js +0 -5
  95. package/dist/factory/_factory.js.map +0 -1
  96. package/src/boundary/boundary.ts +0 -12
  97. package/src/boundary/output/output.ts +0 -3
  98. /package/dist/boundary/input/{parsers/parsers.js → parsers.js} +0 -0
  99. /package/dist/boundary/input/{plugins/plugins.js → plugins.js} +0 -0
  100. /package/dist/boundary/{input/input.js → input.js} +0 -0
  101. /package/dist/boundary/output/{config/IConfig.d.ts → IConfig.d.ts} +0 -0
  102. /package/dist/boundary/output/{config/IConfig.js → IConfig.js} +0 -0
  103. /package/dist/boundary/{output/output.js → output.js} +0 -0
  104. /package/dist/factory/{Factory.d.ts.map → factory.d.ts.map} +0 -0
  105. /package/dist/factory/{Factory.js.map → factory.js.map} +0 -0
  106. /package/src/boundary/output/{config/IConfig.ts → IConfig.ts} +0 -0
  107. /package/src/boundary/output/{config/interface → interface}/option/IOption.d.ts +0 -0
  108. /package/src/boundary/output/{config/interface → interface}/option/language/IOLanguage.d.ts +0 -0
  109. /package/src/boundary/output/{config/interface → interface}/option/language/ecma/IOLanguageEcma.d.ts +0 -0
  110. /package/src/boundary/output/{config/interface → interface}/option/language/globals/IOLanguageGlobals.d.ts +0 -0
  111. /package/src/boundary/output/{config/interface → interface}/option/language/source/IOLanguageSource.d.ts +0 -0
  112. /package/src/boundary/output/{config/interface → interface}/option/linter/IOLinter.d.ts +0 -0
  113. /package/src/boundary/output/{config/interface → interface}/option/plugins/IOPlugins.d.ts +0 -0
  114. /package/src/boundary/output/{config/interface → interface}/option/processor/IOProcessor.d.ts +0 -0
  115. /package/src/boundary/output/{config/interface → interface}/rules/IRule.d.ts +0 -0
  116. /package/src/boundary/output/{config/interface → interface}/rules/state/RuleSeverity.d.ts +0 -0
  117. /package/src/factory/options/{Options.ts → options.ts} +0 -0
@@ -1,5 +1,5 @@
1
- import type { Scope } from "../../../scopes/scopes.js";
2
- import type { Options } from "../../../factory/factory.js";
1
+ import type { Scope } from "../../scopes/scopes.js";
2
+ import type { Options } from "../../factory/factory.js";
3
3
  type Parsers = {
4
4
  readonly [S in Scope]: ConstructorParameters<typeof Options[S]>[2] extends readonly [unknown, ...unknown[]] ? unknown : null;
5
5
  };
@@ -0,0 +1 @@
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"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"parsers.js","sourceRoot":"","sources":["../../../src/boundary/input/parsers.ts"],"names":[],"mappings":""}
@@ -0,0 +1,7 @@
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
@@ -0,0 +1 @@
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"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugins.js","sourceRoot":"","sources":["../../../src/boundary/input/plugins.ts"],"names":[],"mappings":""}
@@ -0,0 +1,8 @@
1
+ import type plugins from "./input/plugins.js";
2
+ import type parsers from "./input/parsers.js";
3
+ declare namespace Input {
4
+ type Plugins = plugins;
5
+ type Parsers = parsers;
6
+ }
7
+ export type { Input as default };
8
+ //# sourceMappingURL=input.d.ts.map
@@ -0,0 +1 @@
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"}
@@ -1 +1 @@
1
- {"version":3,"file":"input.js","sourceRoot":"","sources":["../../../src/boundary/input/input.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"input.js","sourceRoot":"","sources":["../../src/boundary/input.ts"],"names":[],"mappings":""}
@@ -0,0 +1 @@
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"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IConfig.js","sourceRoot":"","sources":["../../../src/boundary/output/IConfig.ts"],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ import type Output from "./output/IConfig.js";
2
+ export type { Output as default };
3
+ //# sourceMappingURL=output.d.ts.map
@@ -0,0 +1 @@
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"}
@@ -1 +1 @@
1
- {"version":3,"file":"output.js","sourceRoot":"","sources":["../../../src/boundary/output/output.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"output.js","sourceRoot":"","sources":["../../src/boundary/output.ts"],"names":[],"mappings":""}
@@ -1,5 +1,5 @@
1
1
  import Ruleset, { Rule } from "./ruleset/Ruleset.js";
2
2
  import Files from "./files/Files.js";
3
- import Options from "./options/Options.js";
3
+ import Options from "./options/options.js";
4
4
  export { Options, Files, Ruleset, Rule, };
5
5
  //# sourceMappingURL=factory.d.ts.map
@@ -1,5 +1,5 @@
1
1
  import Ruleset, { Rule } from "./ruleset/Ruleset.js";
2
2
  import Files from "./files/Files.js";
3
- import Options from "./options/Options.js";
3
+ import Options from "./options/options.js";
4
4
  export { Options, Files, Ruleset, Rule, };
5
5
  //# sourceMappingURL=factory.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Files.d.ts","sourceRoot":"","sources":["../../../src/factory/files/Files.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,KAAK;IAEtB,OAAO,CAAC,QAAQ,CAAC,IAAI;IACrB,OAAO,CAAC,QAAQ,CAAC,QAAQ;gBADR,IAAI,EAAE,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC,EAC7B,QAAQ,EAAE,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC;IAGhD,KAAK,CAAC,KAAK,EAAE,KAAK,GAAG,SAAS,MAAM,EAAE;CAM9C"}
1
+ {"version":3,"file":"Files.d.ts","sourceRoot":"","sources":["../../../src/factory/files/Files.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,KAAK;IAEtB,OAAO,CAAC,QAAQ,CAAC,IAAI;IACrB,OAAO,CAAC,QAAQ,CAAC,QAAQ;gBADR,IAAI,EAAE,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC,EAC7B,QAAQ,EAAE,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,CAAC;IAGhD,KAAK,CAAC,KAAK,EAAE,KAAK,GAAG,SAAS,MAAM,EAAE;CAc9C"}
@@ -6,10 +6,15 @@ export default class Files {
6
6
  this.includes = includes;
7
7
  }
8
8
  files(scope) {
9
- return [
10
- ...this.base[scope],
11
- ...this.includes[scope] ?? [],
12
- ];
9
+ try {
10
+ return [
11
+ ...this.base[scope],
12
+ ...this.includes[scope] ?? [],
13
+ ];
14
+ }
15
+ catch (e) {
16
+ throw new Error(`linted.factory.Files/scope:${scope}`, { cause: e });
17
+ }
13
18
  }
14
19
  }
15
20
  //# sourceMappingURL=Files.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Files.js","sourceRoot":"","sources":["../../../src/factory/files/Files.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO,OAAO,KAAK;IAEL;IACA;IAFnB,YACmB,IAA6B,EAC7B,QAAoC;QADpC,SAAI,GAAJ,IAAI,CAAyB;QAC7B,aAAQ,GAAR,QAAQ,CAA4B;IACpD,CAAC;IAEG,KAAK,CAAC,KAAY;QACvB,OAAO;YACL,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;YACnB,GAAG,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,EAAE;SAC9B,CAAC;IACJ,CAAC;CACF"}
1
+ {"version":3,"file":"Files.js","sourceRoot":"","sources":["../../../src/factory/files/Files.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO,OAAO,KAAK;IAEL;IACA;IAFnB,YACmB,IAA6B,EAC7B,QAAoC;QADpC,SAAI,GAAJ,IAAI,CAAyB;QAC7B,aAAQ,GAAR,QAAQ,CAA4B;IACpD,CAAC;IAEG,KAAK,CAAC,KAAY;QACvB,IAAI,CAAC;YACH,OAAO;gBACL,GAAG,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC;gBACnB,GAAG,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,EAAE;aAC9B,CAAC;QACJ,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,8BAA8B,KAAK,EAAE,EACrC,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1,31 +1,17 @@
1
1
  import type { Scope } from "../../../scopes/scopes.js";
2
- import type Boundary from "../../../boundary/boundary.js";
3
2
  import type { Ruleset } from "../../factory.js";
3
+ import type Output from "../../../boundary/output.js";
4
4
  export default abstract class Option<S extends Scope, PluginId extends string, IsEcma extends boolean = true, ParserOptions extends object | boolean = false, ParserCount extends 0 | 1 | 2 = 0, GlobalTypes extends string = never, Processor extends object = never> {
5
5
  readonly files: readonly string[];
6
6
  readonly ruleset: Ruleset<S>;
7
7
  readonly plugins: IOPlugins<PluginId>;
8
8
  readonly parser: Tuple<unknown, ParserCount>;
9
- readonly linterOptions: {
10
- readonly noInlineConfig: true;
11
- readonly reportUnusedDisableDirectives: "error";
12
- };
9
+ private readonly linterOptions;
13
10
  abstract readonly scope: literalful<S>;
14
- abstract readonly processor: (Interface<Processor> extends never ? object : Interface<Processor> extends {
15
- "interface": string;
16
- } ? Interface<Processor> : object);
11
+ abstract readonly processor: Interface<Processor> extends never ? object : Interface<Processor> extends Readonly<Record<"processor", string>> ? Interface<Processor> : object;
17
12
  constructor(files: readonly string[], ruleset: Ruleset<S>, plugins: IOPlugins<PluginId>, parser: Tuple<unknown, ParserCount>);
18
- get configs(): Boundary.Output[];
19
- get option(): {
20
- linterOptions: {
21
- readonly noInlineConfig: true;
22
- readonly reportUnusedDisableDirectives: "error";
23
- };
24
- languageOptions: IOLanguage<IsEcma, ParserOptions, GlobalTypes>;
25
- plugins: IOPlugins<PluginId>;
26
- } & (Interface<Processor> extends never ? object : Interface<Processor> extends {
27
- interface: string;
28
- } ? Interface<Processor> : object);
29
- abstract get languageOptions(): IOLanguage<IsEcma, ParserOptions, GlobalTypes>;
13
+ get configs(): Output[];
14
+ private get option();
15
+ protected abstract get languageOptions(): IOLanguage<IsEcma, ParserOptions, GlobalTypes>;
30
16
  }
31
17
  //# sourceMappingURL=Option.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Option.d.ts","sourceRoot":"","sources":["../../../../src/factory/options/option/Option.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AACvD,OAAO,KAAK,QAAQ,MAAM,+BAA+B,CAAC;AAC1D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAEhD,MAAM,CAAC,OAAO,CAAC,QAAQ,OAAO,MAAM,CAClC,CAAC,SAAS,KAAK,EACf,QAAQ,SAAS,MAAM,EACvB,MAAM,SAAS,OAAO,GAAG,IAAI,EAC7B,aAAa,SAAS,MAAM,GAAG,OAAO,GAAG,KAAK,EAC9C,WAAW,SAAS,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,EACjC,WAAW,SAAS,MAAM,GAAG,KAAK,EAClC,SAAS,SAAS,MAAM,GAAG,KAAK;aAWd,KAAK,EAAE,SAAS,MAAM,EAAE;aACxB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;aACnB,OAAO,EAAE,SAAS,CAAC,QAAQ,CAAC;aAC5B,MAAM,EAAE,KAAK,CAAC,OAAO,EAAE,WAAW,CAAC;IAZrD,SAAgB,aAAa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,EAAE;aACxB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;aACnB,OAAO,EAAE,SAAS,CAAC,QAAQ,CAAC;aAC5B,MAAM,EAAE,KAAK,CAAC,OAAO,EAAE,WAAW,CAAC;IAhBrD,OAAO,CAAC,QAAQ,CAAC,aAAa,CAGnB;IAEX,kBAAyB,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC;IAC9C,kBAAyB,SAAS,EAAE,SAAS,CAAC,SAAS,CAAC,SAAS,KAAK,GAClE,MAAM,GACN,SAAS,CAAC,SAAS,CAAC,SAAS,QAAQ,CAAC,MAAM,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC,GAChE,SAAS,CAAC,SAAS,CAAC,GACpB,MAAM,CAAC;gBAGK,KAAK,EAAE,SAAS,MAAM,EAAE,EACxB,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,EACnB,OAAO,EAAE,SAAS,CAAC,QAAQ,CAAC,EAC5B,MAAM,EAAE,KAAK,CAAC,OAAO,EAAE,WAAW,CAAC;IAGrD,IAAW,OAAO,IAAI,MAAM,EAAE,CAuC7B;IAED,OAAO,KAAK,MAAM,GA4BjB;IAED,SAAS,CAAC,QAAQ,KAAK,eAAe,IAAI,UAAU,CAClD,MAAM,EACN,aAAa,EACb,WAAW,CACZ,CAAC;CACH"}
@@ -14,32 +14,42 @@ export default class Option {
14
14
  this.parser = parser;
15
15
  }
16
16
  get configs() {
17
- const { scope, ruleset, files, option, } = this;
18
- if (ruleset.id !== scope)
19
- throw new TypeError(`Option and Ruleset scope mismatch`, { cause: { option: scope, ruleset: ruleset.id } });
20
- else if (files.length < 1)
21
- return [];
22
- else {
23
- const baseName = `scope:${scope}/rule:${ruleset.id}`;
24
- return ruleset.records.map(([ruleId, rules]) => {
25
- const name = `${baseName}+${ruleId}`;
26
- return {
27
- name,
28
- files,
29
- rules,
30
- ...option,
31
- };
32
- });
17
+ try {
18
+ const { scope, ruleset, files, option, } = this;
19
+ if (ruleset.id !== scope)
20
+ throw new TypeError(`Option and Ruleset scope mismatch`, { cause: { option: scope, ruleset: ruleset.id } });
21
+ else if (files.length < 1)
22
+ return [];
23
+ else {
24
+ const baseName = `scope:${scope}/rule:${ruleset.id}`;
25
+ return ruleset.records.map(([ruleId, rules]) => {
26
+ const name = `${baseName}+${ruleId}`;
27
+ return {
28
+ name,
29
+ files,
30
+ rules,
31
+ ...option,
32
+ };
33
+ });
34
+ }
35
+ }
36
+ catch (e) {
37
+ throw new Error(`linted.factory.Option/scope:${this.scope}: configs`, { cause: e });
33
38
  }
34
39
  }
35
40
  get option() {
36
- const { plugins, linterOptions, languageOptions, processor, } = this;
37
- return {
38
- linterOptions,
39
- languageOptions,
40
- plugins,
41
- ...processor,
42
- };
41
+ try {
42
+ const { plugins, linterOptions, languageOptions, processor, } = this;
43
+ return {
44
+ linterOptions,
45
+ languageOptions,
46
+ plugins,
47
+ ...processor,
48
+ };
49
+ }
50
+ catch (e) {
51
+ throw new Error(`linted.factory.Option/scope:${this.scope}: option`, { cause: e });
52
+ }
43
53
  }
44
54
  }
45
55
  //# sourceMappingURL=Option.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Option.js","sourceRoot":"","sources":["../../../../src/factory/options/option/Option.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,OAAO,OAAgB,MAAM;IAkBhB;IACA;IACA;IACA;IAZF,aAAa,GAAG;QAC9B,cAAc,EAAE,IAAI;QACpB,6BAA6B,EAAE,OAAO;KAC9B,CAAC;IAKX,YACkB,KAAwB,EACxB,OAAmB,EACnB,OAA4B,EAC5B,MAAmC;QAHnC,UAAK,GAAL,KAAK,CAAmB;QACxB,YAAO,GAAP,OAAO,CAAY;QACnB,YAAO,GAAP,OAAO,CAAqB;QAC5B,WAAM,GAAN,MAAM,CAA6B;IAClD,CAAC;IAEJ,IAAW,OAAO;QAChB,MAAM,EACJ,KAAK,EACL,OAAO,EACP,KAAK,EACL,MAAM,GACP,GAAG,IAAI,CAAC;QAET,IAAI,OAAO,CAAC,EAAE,KAAK,KAAK;YACtB,MAAM,IAAI,SAAS,CACjB,mCAAmC,EACnC,EAAE,KAAK,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,EAAE,EAAE,CAClD,CAAC;aACC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC;YACvB,OAAO,EAAE,CAAC;aACP,CAAC;YACJ,MAAM,QAAQ,GAAG,SAAS,KAAK,SAAS,OAAO,CAAC,EAAE,EAAW,CAAC;YAE9D,OAAO,OAAO,CAAC,OAAO,CAAC,GAAG,CACxB,CAAC,CAAC,MAAM,EAAE,KAAK,CAAC,EAAE,EAAE;gBAClB,MAAM,IAAI,GAAG,GAAG,QAAQ,IAAI,MAAM,EAAW,CAAC;gBAE9C,OAAO;oBACL,IAAI;oBACJ,KAAK;oBACL,KAAK;oBACL,GAAG,MAAM;iBACV,CAAC;YACJ,CAAC,CACF,CAAC;QACJ,CAAC;IACH,CAAC;IAED,IAAW,MAAM;QACf,MAAM,EACJ,OAAO,EACP,aAAa,EACb,eAAe,EACf,SAAS,GACV,GAAG,IAAI,CAAC;QAET,OAAO;YACL,aAAa;YACb,eAAe;YACf,OAAO;YACP,GAAG,SAAS;SAOb,CAAC;IACJ,CAAC;CAOF"}
1
+ {"version":3,"file":"Option.js","sourceRoot":"","sources":["../../../../src/factory/options/option/Option.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,OAAO,OAAgB,MAAM;IAsBhB;IACA;IACA;IACA;IAhBD,aAAa,GAAG;QAC/B,cAAc,EAAE,IAAI;QACpB,6BAA6B,EAAE,OAAO;KAC9B,CAAC;IASX,YACkB,KAAwB,EACxB,OAAmB,EACnB,OAA4B,EAC5B,MAAmC;QAHnC,UAAK,GAAL,KAAK,CAAmB;QACxB,YAAO,GAAP,OAAO,CAAY;QACnB,YAAO,GAAP,OAAO,CAAqB;QAC5B,WAAM,GAAN,MAAM,CAA6B;IAClD,CAAC;IAEJ,IAAW,OA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J,CAAC;IACH,CAAC;CAOF"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/html/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAAM,CAC5C,MAAM,EACN,cAAc,EACd,KAAK,EACL,IAAI,EACJ,CAAC,CACF;IACC,SAAgB,KAAK,UAAU;IAC/B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAIzB;CACF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/html/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAAM,CAC5C,MAAM,EACN,cAAc,EACd,KAAK,EACL,IAAI,EACJ,CAAC,CACF;IACC,SAAgB,KAAK,UAAU;IAC/B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAYzB;CACF"}
@@ -3,8 +3,13 @@ export default class HtmlOption extends Option {
3
3
  scope = "html";
4
4
  processor = {};
5
5
  get languageOptions() {
6
- const [parser] = this.parser;
7
- return { parser };
6
+ try {
7
+ const [parser] = this.parser;
8
+ return { parser };
9
+ }
10
+ catch (e) {
11
+ throw new Error(`linted.factory.options.html: languageOptions`, { cause: e });
12
+ }
8
13
  }
9
14
  }
10
15
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/html/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAMvC;IACiB,KAAK,GAAG,MAAM,CAAC;IACf,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
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/html/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAMvC;IACiB,KAAK,GAAG,MAAM,CAAC;IACf,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;YAE7B,OAAO,EAAE,MAAM,EAAW,CAAC;QAC7B,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,8CAA8C,EAC9C,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/js/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAAM,CAAC,IAAI,EAAE,YAAY,CAAC;IAC9D,SAAgB,KAAK,QAAQ;IAC7B,SAAgB,SAAS,KAAM;IAE/B,IAAW,eAAe;;;MAKzB;CACF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/js/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAAM,CAAC,IAAI,EAAE,YAAY,CAAC;IAC9D,SAAgB,KAAK,QAAQ;IAC7B,SAAgB,SAAS,KAAM;IAE/B,IAAW,eAAe;;;MAazB;CACF"}
@@ -3,10 +3,15 @@ export default class JsOption extends Option {
3
3
  scope = "js";
4
4
  processor = {};
5
5
  get languageOptions() {
6
- return {
7
- ecmaVersion: "latest",
8
- sourceType: "module",
9
- };
6
+ try {
7
+ return {
8
+ ecmaVersion: "latest",
9
+ sourceType: "module",
10
+ };
11
+ }
12
+ catch (e) {
13
+ throw new Error(`linted.factory.options.js: languageOptions`, { cause: e });
14
+ }
10
15
  }
11
16
  }
12
17
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/js/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAA0B;IAC9C,KAAK,GAAG,IAAI,CAAC;IACb,SAAS,GAAG,EAAE,CAAC;IAE/B,IAAW,eAAe;QACxB,OAAO;YACL,WAAW,EAAE,QAAQ;YACrB,UAAU,EAAE,QAAQ;SACZ,CAAC;IACb,CAAC;CACF"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/js/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAA0B;IAC9C,KAAK,GAAG,IAAI,CAAC;IACb,SAAS,GAAG,EAAE,CAAC;IAE/B,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,OAAO;gBACL,WAAW,EAAE,QAAQ;gBACrB,UAAU,EAAE,QAAQ;aACZ,CAAC;QACb,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,4CAA4C,EAC5C,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/json/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAAM,CAC5C,MAAM,EACN,OAAO,EACP,KAAK,EACL,IAAI,EACJ,CAAC,CACF;IACC,SAAgB,KAAK,UAAU;IAC/B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAIzB;CACF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/factory/options/option/json/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAAM,CAC5C,MAAM,EACN,OAAO,EACP,KAAK,EACL,IAAI,EACJ,CAAC,CACF;IACC,SAAgB,KAAK,UAAU;IAC/B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAYzB;CACF"}
@@ -3,8 +3,13 @@ export default class JsonOption extends Option {
3
3
  scope = "json";
4
4
  processor = {};
5
5
  get languageOptions() {
6
- const [parser] = this.parser;
7
- return { parser };
6
+ try {
7
+ const [parser] = this.parser;
8
+ return { parser };
9
+ }
10
+ catch (e) {
11
+ throw new Error(`linted.factory.options.json: languageOptions`, { cause: e });
12
+ }
8
13
  }
9
14
  }
10
15
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/json/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAMvC;IACiB,KAAK,GAAG,MAAM,CAAC;IACf,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
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/factory/options/option/json/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,MAMvC;IACiB,KAAK,GAAG,MAAM,CAAC;IACf,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;YAE7B,OAAO,EAAE,MAAM,EAAW,CAAC;QAC7B,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,8CAA8C,EAC9C,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1 +1 @@
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,KAAK,WAAW;IAChC,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAIzB;CACF"}
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,KAAK,WAAW;IAChC,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAYzB;CACF"}
@@ -3,8 +3,13 @@ export default class JsoncOption extends Option {
3
3
  scope = "jsonc";
4
4
  processor = {};
5
5
  get languageOptions() {
6
- const [parser] = this.parser;
7
- return { parser };
6
+ try {
7
+ const [parser] = this.parser;
8
+ return { parser };
9
+ }
10
+ catch (e) {
11
+ throw new Error(`linted.factory.options.jsonc: languageOptions`, { cause: e });
12
+ }
8
13
  }
9
14
  }
10
15
  //# 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,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,MAMxC;IACiB,KAAK,GAAG,OAAO,CAAC;IAChB,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
+ {"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,KAAK,GAAG,OAAO,CAAC;IAChB,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;YAE7B,OAAO,EAAE,MAAM,EAAW,CAAC;QAC7B,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,+CAA+C,EAC/C,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1 +1 @@
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,KAAK,YAAY;IACjC,SAAgB,SAAS;;MAA2C;IAEpE,IAAW,eAAe;;;;;;;;;;;MAezB;CACF"}
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,KAAK,YAAY;IACjC,SAAgB,SAAS;;MAA2C;IAEpE,IAAW,eAAe;;;;;;;;;;;MAuBzB;CACF"}
@@ -3,19 +3,24 @@ export default class SvelteOption extends Option {
3
3
  scope = "svelte";
4
4
  processor = { processor: "svelte/svelte" };
5
5
  get languageOptions() {
6
- const [parser, tsParser] = this.parser;
7
- return {
8
- ecmaVersion: "latest",
9
- sourceType: "module",
10
- parser,
11
- parserOptions: {
6
+ try {
7
+ const [parser, tsParser] = this.parser;
8
+ return {
12
9
  ecmaVersion: "latest",
13
10
  sourceType: "module",
14
- project: "tsconfig.json",
15
- extraFileExtensions: [".svelte"],
16
- parser: tsParser,
17
- },
18
- };
11
+ parser,
12
+ parserOptions: {
13
+ ecmaVersion: "latest",
14
+ sourceType: "module",
15
+ project: "tsconfig.json",
16
+ extraFileExtensions: [".svelte"],
17
+ parser: tsParser,
18
+ },
19
+ };
20
+ }
21
+ catch (e) {
22
+ throw new Error(`linted.factory.options.svelte: languageOptions`, { cause: e });
23
+ }
19
24
  }
20
25
  }
21
26
  //# 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,cAAc,CAAC;AAGlC,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,MAUzC;IACiB,KAAK,GAAG,QAAQ,CAAC;IACjB,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
+ {"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,KAAK,GAAG,QAAQ,CAAC;IACjB,SAAS,GAAG,EAAE,SAAS,EAAE,eAAe,EAAW,CAAC;IAEpE,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;YAEvC,OAAO;gBACL,WAAW,EAAE,QAAQ;gBACrB,UAAU,EAAE,QAAQ;gBACpB,MAAM;gBACN,aAAa,EAAE;oBACb,WAAW,EAAE,QAAQ;oBACrB,UAAU,EAAE,QAAQ;oBACpB,OAAO,EAAE,eAAe;oBACxB,mBAAmB,EAAE,CAAC,SAAS,CAAU;oBACzC,MAAM,EAAE,QAAQ;iBACjB;aACO,CAAC;QACb,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,gDAAgD,EAChD,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1 +1 @@
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,KAAK,QAAQ;IAC7B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;;;;;;;;MAazB;CACF"}
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,KAAK,QAAQ;IAC7B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;;;;;;;;MAqBzB;CACF"}
@@ -3,17 +3,22 @@ export default class TsOption extends Option {
3
3
  scope = "ts";
4
4
  processor = {};
5
5
  get languageOptions() {
6
- const [parser] = this.parser;
7
- return {
8
- ecmaVersion: "latest",
9
- sourceType: "module",
10
- parser,
11
- parserOptions: {
6
+ try {
7
+ const [parser] = this.parser;
8
+ return {
12
9
  ecmaVersion: "latest",
13
10
  sourceType: "module",
14
- project: "tsconfig.json",
15
- },
16
- };
11
+ parser,
12
+ parserOptions: {
13
+ ecmaVersion: "latest",
14
+ sourceType: "module",
15
+ project: "tsconfig.json",
16
+ },
17
+ };
18
+ }
19
+ catch (e) {
20
+ throw new Error(`linted.factory.options.ts: languageOptions`, { cause: e });
21
+ }
17
22
  }
18
23
  }
19
24
  //# 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,cAAc,CAAC;AAGlC,MAAM,CAAC,OAAO,OAAO,QAAS,SAAQ,MAOrC;IACiB,KAAK,GAAG,IAAI,CAAC;IACb,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
+ {"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,KAAK,GAAG,IAAI,CAAC;IACb,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;YAE7B,OAAO;gBACL,WAAW,EAAE,QAAQ;gBACrB,UAAU,EAAE,QAAQ;gBACpB,MAAM;gBACN,aAAa,EAAE;oBACb,WAAW,EAAE,QAAQ;oBACrB,UAAU,EAAE,QAAQ;oBACpB,OAAO,EAAE,eAAe;iBACzB;aACO,CAAC;QACb,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,4CAA4C,EAC5C,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -1 +1 @@
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,KAAK,SAAS;IAC9B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAIzB;CACF"}
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,KAAK,SAAS;IAC9B,SAAgB,SAAS,KAAe;IAExC,IAAW,eAAe;;MAYzB;CACF"}
@@ -3,8 +3,13 @@ export default class YmlOption extends Option {
3
3
  scope = "yml";
4
4
  processor = {};
5
5
  get languageOptions() {
6
- const [parser] = this.parser;
7
- return { parser };
6
+ try {
7
+ const [parser] = this.parser;
8
+ return { parser };
9
+ }
10
+ catch (e) {
11
+ throw new Error(`linted.factory.options.yml: languageOptions`, { cause: e });
12
+ }
8
13
  }
9
14
  }
10
15
  //# 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,cAAc,CAAC;AAElC,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,MAMtC;IACiB,KAAK,GAAG,KAAK,CAAC;IACd,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
+ {"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,KAAK,GAAG,KAAK,CAAC;IACd,SAAS,GAAG,EAAW,CAAC;IAExC,IAAW,eAAe;QACxB,IAAI,CAAC;YACH,MAAM,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC;YAE7B,OAAO,EAAE,MAAM,EAAW,CAAC;QAC7B,CAAC;QACD,OAAO,CAAC,EAAE,CAAC;YACT,MAAM,IAAI,KAAK,CACb,6CAA6C,EAC7C,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;QACJ,CAAC;IACH,CAAC;CACF"}
@@ -15,4 +15,4 @@ declare const _default: {
15
15
  readonly yml: typeof YmlOption;
16
16
  };
17
17
  export default _default;
18
- //# sourceMappingURL=Options.d.ts.map
18
+ //# sourceMappingURL=options.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Options.d.ts","sourceRoot":"","sources":["../../../src/factory/options/Options.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,YAAY,MAAM,0BAA0B,CAAC;AACpD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,WAAW,MAAM,yBAAyB,CAAC;AAClD,OAAO,SAAS,MAAM,uBAAuB,CAAC;;;;;;;;;;AAE9C,wBAQW"}
1
+ {"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../../src/factory/options/options.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,YAAY,MAAM,0BAA0B,CAAC;AACpD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,WAAW,MAAM,yBAAyB,CAAC;AAClD,OAAO,SAAS,MAAM,uBAAuB,CAAC;;;;;;;;;;AAE9C,wBAQW"}
@@ -14,4 +14,4 @@ export default {
14
14
  jsonc: JsoncOption,
15
15
  yml: YmlOption,
16
16
  };
17
- //# sourceMappingURL=Options.js.map
17
+ //# sourceMappingURL=options.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Options.js","sourceRoot":"","sources":["../../../src/factory/options/Options.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,YAAY,MAAM,0BAA0B,CAAC;AACpD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,WAAW,MAAM,yBAAyB,CAAC;AAClD,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAE9C,eAAe;IACb,EAAE,EAAE,QAAQ;IACZ,EAAE,EAAE,QAAQ;IACZ,MAAM,EAAE,YAAY;IACpB,IAAI,EAAE,UAAU;IAChB,IAAI,EAAE,UAAU;IAChB,KAAK,EAAE,WAAW;IAClB,GAAG,EAAE,SAAS;CACN,CAAC"}
1
+ {"version":3,"file":"options.js","sourceRoot":"","sources":["../../../src/factory/options/options.ts"],"names":[],"mappings":"AAAA,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,YAAY,MAAM,0BAA0B,CAAC;AACpD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,UAAU,MAAM,wBAAwB,CAAC;AAChD,OAAO,WAAW,MAAM,yBAAyB,CAAC;AAClD,OAAO,SAAS,MAAM,uBAAuB,CAAC;AAE9C,eAAe;IACb,EAAE,EAAE,QAAQ;IACZ,EAAE,EAAE,QAAQ;IACZ,MAAM,EAAE,YAAY;IACpB,IAAI,EAAE,UAAU;IAChB,IAAI,EAAE,UAAU;IAChB,KAAK,EAAE,WAAW;IAClB,GAAG,EAAE,SAAS;CACN,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"Ruleset.d.ts","sourceRoot":"","sources":["../../../src/factory/ruleset/Ruleset.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AACpD,OAAO,IAAI,MAAM,gBAAgB,CAAC;AAElC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO,CAAC,CAAC,SAAS,KAAK;IAKxC,OAAO,CAAC,QAAQ,CAAC,KAAK;IAJxB,SAAgB,OAAO,EAAE,SAAS,IAAI,EAAE,CAAC;IAClC,SAAS,EAAE,IAAI,CAAC,IAAI,CAAC,CAAQ;gBAGjB,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,EACrC,GAAG,OAAO,EAAE,SAAS,IAAI,EAAE;IAK7B,IAAW,EAAE,kBAIZ;IAED,IAAW,OAAO,iCAOjB;IAEM,QAAQ,CAAC,SAAS,EAAE,SAAS,GAAG,KAAK;CAS7C"}
1
+ {"version":3,"file":"Ruleset.d.ts","sourceRoot":"","sources":["../../../src/factory/ruleset/Ruleset.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AACpD,OAAO,IAAI,MAAM,gBAAgB,CAAC;AAElC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO,CAAC,CAAC,SAAS,KAAK;IAKxC,OAAO,CAAC,QAAQ,CAAC,KAAK;IAJxB,SAAgB,OAAO,EAAE,SAAS,IAAI,EAAE,CAAC;IAClC,SAAS,EAAE,IAAI,CAAC,IAAI,CAAC,CAAQ;gBAGjB,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,EACrC,GAAG,OAAO,EAAE,SAAS,IAAI,EAAE;IAa7B,IAAW,EAAE,kBAYZ;IAED,IAAW,OAAO,iCAejB;IAEM,QAAQ,CAAC,SAAS,EAAE,SAAS,GAAG,KAAK;CAiB7C"}
@@ -6,23 +6,43 @@ export default class Ruleset {
6
6
  overrides = null;
7
7
  constructor(scope, ...ruleset) {
8
8
  this.scope = scope;
9
- this.ruleset = [...ruleset];
9
+ try {
10
+ this.ruleset = [...ruleset];
11
+ }
12
+ catch (e) {
13
+ throw new Error(`linted.factory.Ruleset`, { cause: e });
14
+ }
10
15
  }
11
16
  get id() {
12
- const { scope } = this;
13
- return scope;
17
+ try {
18
+ const { scope } = this;
19
+ return scope;
20
+ }
21
+ catch (e) {
22
+ throw new Error(`linted.factory.Ruleset: id`, { cause: e });
23
+ }
14
24
  }
15
25
  get records() {
16
- const { ruleset, overrides } = this;
17
- return [
18
- ...ruleset.map(rules => [rules.id, rules.rules]),
19
- ...overrides === null ? [] : [[overrides.id, overrides.rules]],
20
- ];
26
+ try {
27
+ const { ruleset, overrides } = this;
28
+ return [
29
+ ...ruleset.map(rules => [rules.id, rules.rules]),
30
+ ...overrides === null ? [] : [[overrides.id, overrides.rules]],
31
+ ];
32
+ }
33
+ catch (e) {
34
+ throw new Error(`linted.factory.Ruleset: records`, { cause: e });
35
+ }
21
36
  }
22
37
  override(overrides) {
23
- if (typeof overrides !== "undefined")
24
- this.overrides = new Rule("override", overrides);
25
- return this;
38
+ try {
39
+ if (typeof overrides !== "undefined")
40
+ this.overrides = new Rule("override", overrides);
41
+ return this;
42
+ }
43
+ catch (e) {
44
+ throw new Error(`linted.factory.Ruleset: override`, { cause: e });
45
+ }
26
46
  }
27
47
  }
28
48
  //# sourceMappingURL=Ruleset.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Ruleset.js","sourceRoot":"","sources":["../../../src/factory/ruleset/Ruleset.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,gBAAgB,CAAC;AAElC,OAAO,EAAE,IAAI,EAAE,CAAC;AAChB,MAAM,CAAC,OAAO,OAAO,OAAO;IAKP;IAJH,OAAO,CAAkB;IAClC,SAAS,GAAe,IAAI,CAAC;IAEpC,YACmB,KAAoB,EACrC,GAAG,OAAwB;QADV,UAAK,GAAL,KAAK,CAAe;QAGrC,IAAI,CAAC,OAAO,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC;IAC9B,CAAC;IAED,IAAW,EAAE;QACX,MAAM,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC;QAEvB,O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