@eslinted/core 0.0.1-rc.8 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.d.ts CHANGED
@@ -7,7 +7,7 @@ export { default as Ruleset } from "./ruleset/Ruleset.js";
7
7
  export { Rule } from "./ruleset/Ruleset.js";
8
8
  export type { Scopes } from "./scopes.js";
9
9
  export type { default as IConfig } from "./interface/IConfig.js";
10
- export default function (plugins: Plugins, parsers: Parsers, files: Record<Scopes, string[]>, rulesets: {
10
+ export default function (plugins: Plugins, parsers: Parsers, files: Record<"defaults" | "includes", Record<Scopes, string[]>>, rulesets: {
11
11
  [S in Scopes]: Ruleset<S>;
12
12
  }): IConfig[];
13
13
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,OAAO,MAAM,wBAAwB,CAAC;AAClD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,OAAO,MAAM,cAAc,CAAC;AACxC,OAAO,KAAK,OAAO,MAAM,cAAc,CAAC;AACxC,OAAO,KAAK,OAAO,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,YAAY,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjE,MAAM,CAAC,OAAO,WACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,EAC/B,QAAQ,EAAE;KAAG,CAAC,IAAI,MAAM,GAAG,OAAO,CAAC,CAAC,CAAC;CAAE,GACtC,OAAO,EAAE,CAkFX"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,OAAO,MAAM,wBAAwB,CAAC;AAClD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,OAAO,MAAM,cAAc,CAAC;AACxC,OAAO,KAAK,OAAO,MAAM,cAAc,CAAC;AACxC,OAAO,KAAK,OAAO,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,YAAY,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjE,MAAM,CAAC,OAAO,WACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,MAAM,CACT,UAAU,GACV,UAAU,EAEZ,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CACzB,EACD,QAAQ,EAAE;KAAG,CAAC,IAAI,MAAM,GAAG,OAAO,CAAC,CAAC,CAAC;CAAE,GACtC,OAAO,EAAE,CAyFX"}
package/dist/index.js CHANGED
@@ -6,25 +6,25 @@ export default function (plugins, parsers, files, rulesets) {
6
6
  try {
7
7
  const instantiatedOptions = {
8
8
  js: new options
9
- .js(plugins.js, ...files.js)
9
+ .js(plugins.js, ...files.defaults.js, ...files.includes.js)
10
10
  .body,
11
11
  ts: new options
12
- .ts(plugins.ts, parsers.ts, ...files.ts)
12
+ .ts(plugins.ts, parsers.ts, ...files.defaults.ts, ...files.includes.ts)
13
13
  .body,
14
14
  svelte: new options
15
- .svelte(plugins.svelte, parsers.svelte, parsers.ts, ...files.svelte)
15
+ .svelte(plugins.svelte, parsers.svelte, parsers.ts, ...files.defaults.svelte, ...files.includes.svelte)
16
16
  .body,
17
17
  html: new options
18
- .html(plugins.html, parsers.html, ...files.html)
18
+ .html(plugins.html, parsers.html, ...files.defaults.html, ...files.includes.html)
19
19
  .body,
20
20
  json: new options
21
- .json(plugins.json, parsers.json, ...files.json)
21
+ .json(plugins.json, parsers.json, ...files.defaults.json, ...files.includes.json)
22
22
  .body,
23
23
  jsonc: new options
24
- .jsonc(plugins.jsonc, parsers.jsonc, ...files.jsonc)
24
+ .jsonc(plugins.jsonc, parsers.jsonc, ...files.defaults.jsonc, ...files.includes.jsonc)
25
25
  .body,
26
26
  yml: new options
27
- .yml(plugins.yml, parsers.yml, ...files.yml)
27
+ .yml(plugins.yml, parsers.yml, ...files.defaults.yml, ...files.includes.yml)
28
28
  .body,
29
29
  };
30
30
  return scopes
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,aAAa,CAAC;AACjC,OAAO,OAAO,MAAM,cAAc,CAAC;AAOnC,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAG5C,MAAM,CAAC,OAAO,WACZ,OAAgB,EAChB,OAAgB,EAChB,KAA+B,EAC/B,QAAuC;IAEvC,IAAI,CAAC;QACH,MAAM,mBAAmB,GAIrB;YACF,EAAE,EAAE,IAAI,OAAO;iBACZ,EAAE,CACD,OAAO,CAAC,EAAE,EACV,GAAG,KAAK,CAAC,EAAE,CACZ;iBACA,IAAI;YACP,EAAE,EAAE,IAAI,OAAO;iBACZ,EAAE,CACD,OAAO,CAAC,EAAE,EACV,OAAO,CAAC,EAAE,EACV,GAAG,KAAK,CAAC,EAAE,CACZ;iBACA,IAAI;YACP,MAAM,EAAE,IAAI,OAAO;iBAChB,MAAM,CACL,OAAO,CAAC,MAAM,EACd,OAAO,CAAC,MAAM,EACd,OAAO,CAAC,EAAE,EACV,GAAG,KAAK,CAAC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,KAAK,EACb,OAAO,CAAC,KAAK,EACb,GAAG,KAAK,CAAC,QAAQ,CAAC,KAAK,EACvB,GAAG,KAAK,CAAC,QAAQ,CAAC,KAAK,CACxB;iBACA,IAAI;YACP,GAAG,EAAE,IAAI,OAAO;iBACb,GAAG,CACF,OAAO,CAAC,GAAG,EACX,OAAO,CAAC,GAAG,EACX,GAAG,KAAK,CAAC,QAAQ,CAAC,GAAG,EACrB,GAAG,KAAK,CAAC,QAAQ,CAAC,GAAG,CACtB;iBACA,IAAI;SACR,CAAC;QAEF,OAAO,MAAM;aACV,GAAG,CACF,KAAK,CAAC,EAAE,CACN,mBAAmB,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC;YACzC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC;iBACd,IAAI;iBACJ,GAAG,CACF,KAAK,CAAC,EAAE;gBACN,OAAO;oBACL,KAAK;oBACL,GAAG,mBAAmB,CAAC,KAAK,CAAC;iBAC9B,CAAC;YACJ,CAAC,CACF;YACH,CAAC,CAAC,EAAE,CACT;aACA,IAAI,EAAE,CAAC;IACZ,CAAC;IACD,OAAO,CAAC,EAAE,CAAC;QACT,MAAM,IAAI,KAAK,CACb,6BAA6B,EAC7B,EAAE,KAAK,EAAE,CAAC,EAAE,CACb,CAAC;IACJ,CAAC;AACH,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eslinted/core",
3
- "version": "0.0.1-rc.8",
3
+ "version": "0.1.0",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",
package/src/index.ts CHANGED
@@ -13,7 +13,12 @@ export type { default as IConfig } from "./interface/IConfig.js";
13
13
  export default function (
14
14
  plugins: Plugins,
15
15
  parsers: Parsers,
16
- files: Record<Scopes, string[]>,
16
+ files: Record<
17
+ | "defaults"
18
+ | "includes"
19
+ ,
20
+ Record<Scopes, string[]>
21
+ >,
17
22
  rulesets: { [S in Scopes]: Ruleset<S> },
18
23
  ): IConfig[] {
19
24
  try {
@@ -25,14 +30,16 @@ export default function (
25
30
  js: new options
26
31
  .js(
27
32
  plugins.js,
28
- ...files.js,
33
+ ...files.defaults.js,
34
+ ...files.includes.js,
29
35
  )
30
36
  .body,
31
37
  ts: new options
32
38
  .ts(
33
39
  plugins.ts,
34
40
  parsers.ts,
35
- ...files.ts,
41
+ ...files.defaults.ts,
42
+ ...files.includes.ts,
36
43
  )
37
44
  .body,
38
45
  svelte: new options
@@ -40,35 +47,40 @@ export default function (
40
47
  plugins.svelte,
41
48
  parsers.svelte,
42
49
  parsers.ts,
43
- ...files.svelte,
50
+ ...files.defaults.svelte,
51
+ ...files.includes.svelte,
44
52
  )
45
53
  .body,
46
54
  html: new options
47
55
  .html(
48
56
  plugins.html,
49
57
  parsers.html,
50
- ...files.html,
58
+ ...files.defaults.html,
59
+ ...files.includes.html,
51
60
  )
52
61
  .body,
53
62
  json: new options
54
63
  .json(
55
64
  plugins.json,
56
65
  parsers.json,
57
- ...files.json,
66
+ ...files.defaults.json,
67
+ ...files.includes.json,
58
68
  )
59
69
  .body,
60
70
  jsonc: new options
61
71
  .jsonc(
62
72
  plugins.jsonc,
63
73
  parsers.jsonc,
64
- ...files.jsonc,
74
+ ...files.defaults.jsonc,
75
+ ...files.includes.jsonc,
65
76
  )
66
77
  .body,
67
78
  yml: new options
68
79
  .yml(
69
80
  plugins.yml,
70
81
  parsers.yml,
71
- ...files.yml,
82
+ ...files.defaults.yml,
83
+ ...files.includes.yml,
72
84
  )
73
85
  .body,
74
86
  };