@eslinted/core 22.1.4 → 22.1.5-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/.github/workflows/RELEASE.yml +36 -36
  2. package/.github/workflows/rc.yml +36 -36
  3. package/.markdownlint.jsonc +128 -128
  4. package/.mocharc.yml +15 -15
  5. package/LICENSE +20 -20
  6. package/README.md +4 -4
  7. package/eslint.config.js +3 -3
  8. package/package.json +55 -55
  9. package/src/_test/index.ts +266 -266
  10. package/src/factory.ts +306 -306
  11. package/src/index.spec.ts +106 -106
  12. package/src/index.ts +87 -87
  13. package/src/interface/config/index.ts +42 -42
  14. package/src/interface/config/rule.ts +12 -12
  15. package/src/interface/index.ts +3 -3
  16. package/src/interface/input/configuration/attachment.ts +13 -13
  17. package/src/interface/input/configuration/defaults.ts +24 -24
  18. package/src/interface/input/configuration/extensions.ts +25 -25
  19. package/src/interface/input/configuration/index.ts +17 -17
  20. package/src/interface/input/configuration/manifest/index.ts +15 -15
  21. package/src/interface/input/configuration/settings.ts +18 -18
  22. package/src/interface/input/imports/index.ts +16 -16
  23. package/src/interface/input/imports/optional.ts +11 -11
  24. package/src/interface/input/imports/required.ts +13 -13
  25. package/src/interface/input/index.ts +22 -22
  26. package/src/interface/output/configs/attachment.ts +13 -13
  27. package/src/interface/output/configs/global/ignores.d.ts +6 -6
  28. package/src/interface/output/configs/global/index.d.ts +3 -3
  29. package/src/interface/output/configs/global/plugins.d.ts +6 -6
  30. package/src/interface/output/configs/global/settings.d.ts +11 -11
  31. package/src/interface/output/configs/index.d.ts +3 -3
  32. package/src/interface/output/configs/scoped/index.d.ts +2 -2
  33. package/src/interface/output/configs/scoped/rules.d.ts +12 -12
  34. package/src/interface/output/configs/scoped/settings.d.ts +15 -15
  35. package/src/interface/output/index.d.ts +12 -12
  36. package/src/scope/dependencies/index.ts +2 -2
  37. package/src/scope/dependencies/parsers.ts +5 -5
  38. package/src/scope/dependencies/plugins.ts +12 -12
  39. package/src/scope/index.spec.ts +136 -136
  40. package/src/scope/index.ts +18 -18
  41. package/src/scope/tree/index.spec.ts +124 -124
  42. package/src/scope/tree/index.ts +22 -22
  43. package/tsconfig.json +156 -156
@@ -1,15 +1,15 @@
1
- export interface ScopeManifest<
2
- Parser extends string,
3
- > {
4
- languageOptions: {
5
- [property: string]: unknown;
6
- parser?: Parser;
7
- globals?: string;
8
- };
9
- parserOptions: {
10
- [property: string]: unknown;
11
- parser?: Parser;
12
- };
13
- language?: string;
14
- processor?: string;
15
- }
1
+ export interface ScopeManifest<
2
+ Parser extends string,
3
+ > {
4
+ languageOptions: {
5
+ [property: string]: unknown;
6
+ parser?: Parser;
7
+ globals?: string;
8
+ };
9
+ parserOptions: {
10
+ [property: string]: unknown;
11
+ parser?: Parser;
12
+ };
13
+ language?: string;
14
+ processor?: string;
15
+ }
@@ -1,18 +1,18 @@
1
- import type { IConfig } from "../../config";
2
- import type { ScopeManifest } from "./manifest";
3
-
4
- export interface Settings<
5
- Scope extends string,
6
- Parser extends string,
7
- > {
8
- global:
9
- & IConfig["linterOptions"]
10
- & IConfig["languageOptions"]
11
- ;
12
- registry: Record<
13
- Scope,
14
- ScopeManifest<
15
- Parser
16
- >
17
- >;
18
- }
1
+ import type { IConfig } from "../../config";
2
+ import type { ScopeManifest } from "./manifest";
3
+
4
+ export interface Settings<
5
+ Scope extends string,
6
+ Parser extends string,
7
+ > {
8
+ global:
9
+ & IConfig["linterOptions"]
10
+ & IConfig["languageOptions"]
11
+ ;
12
+ registry: Record<
13
+ Scope,
14
+ ScopeManifest<
15
+ Parser
16
+ >
17
+ >;
18
+ }
@@ -1,16 +1,16 @@
1
- import type { RequiredImports } from "./required";
2
- import type { OptionalImports } from "./optional";
3
-
4
- export interface Imports<
5
- RequiredPlugin extends string,
6
- RequiredParser extends string,
7
- OptionalImport extends string,
8
- > {
9
- required: RequiredImports<
10
- RequiredPlugin,
11
- RequiredParser
12
- >;
13
- optional?: OptionalImports<
14
- OptionalImport
15
- >;
16
- }
1
+ import type { RequiredImports } from "./required";
2
+ import type { OptionalImports } from "./optional";
3
+
4
+ export interface Imports<
5
+ RequiredPlugin extends string,
6
+ RequiredParser extends string,
7
+ OptionalImport extends string,
8
+ > {
9
+ required: RequiredImports<
10
+ RequiredPlugin,
11
+ RequiredParser
12
+ >;
13
+ optional?: OptionalImports<
14
+ OptionalImport
15
+ >;
16
+ }
@@ -1,11 +1,11 @@
1
- export type OptionalImports<
2
- OptionalImport extends string,
3
- > = Partial<
4
- Record<
5
- OptionalImport,
6
- {
7
- plugin: unknown;
8
- parser: unknown;
9
- }
10
- >
11
- >;
1
+ export type OptionalImports<
2
+ OptionalImport extends string,
3
+ > = Partial<
4
+ Record<
5
+ OptionalImport,
6
+ {
7
+ plugin: unknown;
8
+ parser: unknown;
9
+ }
10
+ >
11
+ >;
@@ -1,13 +1,13 @@
1
- export interface RequiredImports<
2
- RequiredPlugin extends string,
3
- RequiredParser extends string,
4
- > {
5
- plugins: Record<
6
- RequiredPlugin,
7
- unknown
8
- >;
9
- parsers: Record<
10
- RequiredParser,
11
- unknown
12
- >;
13
- }
1
+ export interface RequiredImports<
2
+ RequiredPlugin extends string,
3
+ RequiredParser extends string,
4
+ > {
5
+ plugins: Record<
6
+ RequiredPlugin,
7
+ unknown
8
+ >;
9
+ parsers: Record<
10
+ RequiredParser,
11
+ unknown
12
+ >;
13
+ }
@@ -1,22 +1,22 @@
1
- import type { Imports } from "./imports";
2
- import type { Configuration } from "./configuration";
3
-
4
- export interface Input<
5
- RequiredPlugin extends string,
6
- RequiredParser extends string,
7
- OptionalImport extends string,
8
- Scope extends string,
9
- > {
10
- imports: Imports<
11
- RequiredPlugin,
12
- RequiredParser,
13
- OptionalImport
14
- >;
15
- configuration: Configuration<
16
- Scope,
17
- (
18
- | RequiredParser
19
- | OptionalImport
20
- )
21
- >;
22
- }
1
+ import type { Imports } from "./imports";
2
+ import type { Configuration } from "./configuration";
3
+
4
+ export interface Input<
5
+ RequiredPlugin extends string,
6
+ RequiredParser extends string,
7
+ OptionalImport extends string,
8
+ Scope extends string,
9
+ > {
10
+ imports: Imports<
11
+ RequiredPlugin,
12
+ RequiredParser,
13
+ OptionalImport
14
+ >;
15
+ configuration: Configuration<
16
+ Scope,
17
+ (
18
+ | RequiredParser
19
+ | OptionalImport
20
+ )
21
+ >;
22
+ }
@@ -1,13 +1,13 @@
1
- import type { IConfig } from "../../config";
2
-
3
- export type Attachment
4
- = & {
5
- files: string[];
6
- }
7
- & Partial<
8
- Omit<
9
- IConfig,
10
- "files"
11
- >
12
- >;
13
-
1
+ import type { IConfig } from "../../config";
2
+
3
+ export type Attachment
4
+ = & {
5
+ files: string[];
6
+ }
7
+ & Partial<
8
+ Omit<
9
+ IConfig,
10
+ "files"
11
+ >
12
+ >;
13
+
@@ -1,6 +1,6 @@
1
- import type { IConfig } from "../../../config";
2
-
3
- export interface GlobalIgnores {
4
- name: "linted/*/ignores/";
5
- ignores: IConfig["ignores"];
6
- }
1
+ import type { IConfig } from "../../../config";
2
+
3
+ export interface GlobalIgnores {
4
+ name: "linted/*/ignores/";
5
+ ignores: IConfig["ignores"];
6
+ }
@@ -1,3 +1,3 @@
1
- export type { Plugins } from "./plugins";
2
- export type { Settings } from "./settings";
3
- export type { GlobalIgnores } from "./ignores";
1
+ export type { Plugins } from "./plugins";
2
+ export type { Settings } from "./settings";
3
+ export type { GlobalIgnores } from "./ignores";
@@ -1,6 +1,6 @@
1
- import type { IConfig } from "../../../config";
2
-
3
- export interface Plugins {
4
- name: "linted/*/plugins/";
5
- plugins: IConfig["plugins"];
6
- }
1
+ import type { IConfig } from "../../../config";
2
+
3
+ export interface Plugins {
4
+ name: "linted/*/plugins/";
5
+ plugins: IConfig["plugins"];
6
+ }
@@ -1,11 +1,11 @@
1
- import type { IConfig } from "../../../config";
2
-
3
- export type Settings = {
4
- name: "linted/*/settings/";
5
- } & Pick<
6
- IConfig,
7
- (
8
- | "linterOptions"
9
- | "languageOptions"
10
- )
11
- >;
1
+ import type { IConfig } from "../../../config";
2
+
3
+ export type Settings = {
4
+ name: "linted/*/settings/";
5
+ } & Pick<
6
+ IConfig,
7
+ (
8
+ | "linterOptions"
9
+ | "languageOptions"
10
+ )
11
+ >;
@@ -1,3 +1,3 @@
1
- export type * from "./global";
2
- export type * from "./scoped";
3
- export type { Attachment } from "./attachment";
1
+ export type * from "./global";
2
+ export type * from "./scoped";
3
+ export type { Attachment } from "./attachment";
@@ -1,2 +1,2 @@
1
- export type { ScopeSettings } from "./settings";
2
- export type { ScopeRules } from "./rules";
1
+ export type { ScopeSettings } from "./settings";
2
+ export type { ScopeRules } from "./rules";
@@ -1,12 +1,12 @@
1
- import type { IConfig } from "../../../config";
2
-
3
- export type ScopeRules = {
4
- name: `linted/${string}`;
5
- } & Pick<
6
- IConfig,
7
- (
8
- | "files"
9
- | "ignores"
10
- | "rules"
11
- )
12
- >;
1
+ import type { IConfig } from "../../../config";
2
+
3
+ export type ScopeRules = {
4
+ name: `linted/${string}`;
5
+ } & Pick<
6
+ IConfig,
7
+ (
8
+ | "files"
9
+ | "ignores"
10
+ | "rules"
11
+ )
12
+ >;
@@ -1,15 +1,15 @@
1
- import type { IConfig } from "../../../config";
2
-
3
- export type ScopeSettings = {
4
- name: `linted/${string}`;
5
- languageOptions?: object;
6
- } & Pick<
7
- IConfig,
8
- (
9
- | "files"
10
- | "ignores"
11
- | "processor"
12
- | "language"
13
- | "settings"
14
- )
15
- >;
1
+ import type { IConfig } from "../../../config";
2
+
3
+ export type ScopeSettings = {
4
+ name: `linted/${string}`;
5
+ languageOptions?: object;
6
+ } & Pick<
7
+ IConfig,
8
+ (
9
+ | "files"
10
+ | "ignores"
11
+ | "processor"
12
+ | "language"
13
+ | "settings"
14
+ )
15
+ >;
@@ -1,12 +1,12 @@
1
- import type * as Config from "./configs";
2
-
3
- export type Output = readonly [
4
- Config.Plugins,
5
- Config.Settings,
6
- Config.GlobalIgnores,
7
- ...(
8
- | Config.ScopeSettings
9
- | Config.ScopeRules
10
- | Config.Attachment
11
- )[],
12
- ];
1
+ import type * as Config from "./configs";
2
+
3
+ export type Output = readonly [
4
+ Config.Plugins,
5
+ Config.Settings,
6
+ Config.GlobalIgnores,
7
+ ...(
8
+ | Config.ScopeSettings
9
+ | Config.ScopeRules
10
+ | Config.Attachment
11
+ )[],
12
+ ];
@@ -1,2 +1,2 @@
1
- export type { RequiredPlugin } from "./plugins";
2
- export type { RequiredParser } from "./parsers";
1
+ export type { RequiredPlugin } from "./plugins";
2
+ export type { RequiredParser } from "./parsers";
@@ -1,5 +1,5 @@
1
- export type RequiredParser
2
- = | "ts"
3
- | "html"
4
- | "yml";
5
-
1
+ export type RequiredParser
2
+ = | "ts"
3
+ | "html"
4
+ | "yml";
5
+
@@ -1,12 +1,12 @@
1
- export type RequiredPlugin
2
- = | "@stylistic"
3
- | "@typescript-eslint"
4
- | "mocha"
5
- | "chai-friendly"
6
- | "chai-expect"
7
- | "@html-eslint"
8
- | "css"
9
- | "json"
10
- | "jsonc"
11
- | "yml";
12
-
1
+ export type RequiredPlugin
2
+ = | "@stylistic"
3
+ | "@typescript-eslint"
4
+ | "mocha"
5
+ | "chai-friendly"
6
+ | "chai-expect"
7
+ | "@html-eslint"
8
+ | "css"
9
+ | "json"
10
+ | "jsonc"
11
+ | "yml";
12
+