eslint-config-complete 2.1.0 → 2.1.2

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 (36) hide show
  1. package/dist/base/base-complete.d.ts +1 -1
  2. package/dist/base/base-complete.d.ts.map +1 -1
  3. package/dist/base/base-complete.js +7 -2
  4. package/dist/base/base-eslint.d.ts +1 -1
  5. package/dist/base/base-eslint.d.ts.map +1 -1
  6. package/dist/base/base-eslint.js +3 -2
  7. package/dist/base/base-import-x.d.ts +1 -1
  8. package/dist/base/base-import-x.d.ts.map +1 -1
  9. package/dist/base/base-import-x.js +8 -5
  10. package/dist/base/base-jsdoc.d.ts +1 -1
  11. package/dist/base/base-jsdoc.d.ts.map +1 -1
  12. package/dist/base/base-jsdoc.js +2 -2
  13. package/dist/base/base-n.d.ts +1 -1
  14. package/dist/base/base-n.d.ts.map +1 -1
  15. package/dist/base/base-n.js +2 -2
  16. package/dist/base/base-package-json.d.ts +6 -0
  17. package/dist/base/base-package-json.d.ts.map +1 -0
  18. package/dist/base/base-package-json.js +92 -0
  19. package/dist/base/base-stylistic.d.ts +1 -1
  20. package/dist/base/base-stylistic.d.ts.map +1 -1
  21. package/dist/base/base-stylistic.js +2 -2
  22. package/dist/base/base-typescript-eslint.d.ts +1 -1
  23. package/dist/base/base-typescript-eslint.d.ts.map +1 -1
  24. package/dist/base/base-typescript-eslint.js +5 -1
  25. package/dist/base/base-unicorn.d.ts +1 -1
  26. package/dist/base/base-unicorn.d.ts.map +1 -1
  27. package/dist/base/base-unicorn.js +6 -2
  28. package/dist/base.d.ts +1 -1
  29. package/dist/base.d.ts.map +1 -1
  30. package/dist/base.js +4 -3
  31. package/dist/eslint-plugin.d.ts +8 -0
  32. package/dist/eslint-plugin.d.ts.map +1 -0
  33. package/dist/eslint-plugin.js +63 -0
  34. package/dist/index.d.ts +1 -0
  35. package/dist/index.js +1 -0
  36. package/package.json +15 -12
@@ -2,5 +2,5 @@
2
2
  * This ESLint config only contains rules from `eslint-plugin-complete`:
3
3
  * https://complete-ts.github.io/eslint-plugin-complete
4
4
  */
5
- export const baseComplete: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
5
+ export const baseComplete: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
6
6
  //# sourceMappingURL=base-complete.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-complete.d.ts","sourceRoot":"","sources":["../../src/base/base-complete.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,+FA2DE"}
1
+ {"version":3,"file":"base-complete.d.ts","sourceRoot":"","sources":["../../src/base/base-complete.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,iGAiEE"}
@@ -1,11 +1,13 @@
1
1
  import ESLintPluginComplete from "eslint-plugin-complete";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * This ESLint config only contains rules from `eslint-plugin-complete`:
5
5
  * https://complete-ts.github.io/eslint-plugin-complete
6
6
  */
7
- export const baseComplete = tseslint.config({
7
+ export const baseComplete = defineConfig({
8
8
  plugins: {
9
+ // TODO: The `defineConfig` helper function is bugged.
10
+ // @ts-expect-error https://github.com/typescript-eslint/typescript-eslint/issues/11543
9
11
  complete: ESLintPluginComplete,
10
12
  },
11
13
  rules: {
@@ -50,6 +52,9 @@ export const baseComplete = tseslint.config({
50
52
  "complete/strict-undefined-functions": "warn",
51
53
  "complete/strict-void-functions": "warn",
52
54
  },
55
+ // Having TypeScript rules apply to ".json" files will throw an error about needing type
56
+ // information.
57
+ ignores: ["*.json"],
53
58
  }, {
54
59
  files: ["**/*.js", "**/*.cjs", "**/*.mjs", "**/*.jsx"],
55
60
  rules: {
@@ -7,5 +7,5 @@
7
7
  * 2) Suggestions
8
8
  * 3) Layout & Formatting
9
9
  */
10
- export const baseESLint: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
10
+ export const baseESLint: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
11
11
  //# sourceMappingURL=base-eslint.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-eslint.d.ts","sourceRoot":"","sources":["../../src/base/base-eslint.js"],"names":[],"mappings":"AAymBA;;;;;;;;GAQG;AACH,6FAMG"}
1
+ {"version":3,"file":"base-eslint.d.ts","sourceRoot":"","sources":["../../src/base/base-eslint.js"],"names":[],"mappings":"AA0mBA;;;;;;;;GAQG;AACH,+FAMG"}
@@ -1,5 +1,5 @@
1
1
  import confusingBrowserGlobals from "confusing-browser-globals";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * @type {Record<string, import("@typescript-eslint/utils").TSESLint.SharedConfig.RuleEntry>}
5
5
  * @see https://eslint.org/docs/latest/rules/#possible-problems
@@ -469,6 +469,7 @@ const SUGGESTIONS = {
469
469
  "prefer-rest-params": "warn",
470
470
  "prefer-spread": "warn",
471
471
  "prefer-template": "warn",
472
+ "preserve-caught-error": "warn",
472
473
  radix: "warn",
473
474
  /** Superseded by the `@typescript-eslint/require-await` rule. */
474
475
  "require-await": "off",
@@ -509,7 +510,7 @@ const LAYOUT_AND_FORMATTING = {
509
510
  * 2) Suggestions
510
511
  * 3) Layout & Formatting
511
512
  */
512
- export const baseESLint = tseslint.config({
513
+ export const baseESLint = defineConfig({
513
514
  rules: {
514
515
  ...POSSIBLE_PROBLEMS,
515
516
  ...SUGGESTIONS,
@@ -8,5 +8,5 @@
8
8
  * 3) Static analysis
9
9
  * 4) Style guide
10
10
  */
11
- export const baseImportX: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
11
+ export const baseImportX: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
12
12
  //# sourceMappingURL=base-import-x.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-import-x.d.ts","sourceRoot":"","sources":["../../src/base/base-import-x.js"],"names":[],"mappings":"AAyOA;;;;;;;;;GASG;AACH,8FA6GE"}
1
+ {"version":3,"file":"base-import-x.d.ts","sourceRoot":"","sources":["../../src/base/base-import-x.js"],"names":[],"mappings":"AAyOA;;;;;;;;;GASG;AACH,gGAgHE"}
@@ -1,5 +1,5 @@
1
1
  import ESLintPluginImportX from "eslint-plugin-import-x";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * @type {Record<string, import("@typescript-eslint/utils").TSESLint.SharedConfig.RuleEntry>}
5
5
  * @see https://github.com/un-ts/eslint-plugin-import-x/blob/master/README.md#helpful-warnings
@@ -197,8 +197,9 @@ const ALL_EXTENSIONS = [
197
197
  * 3) Static analysis
198
198
  * 4) Style guide
199
199
  */
200
- export const baseImportX = tseslint.config({
200
+ export const baseImportX = defineConfig({
201
201
  plugins: {
202
+ // @ts-expect-error https://github.com/un-ts/eslint-plugin-import-x/issues/421
202
203
  "import-x": ESLintPluginImportX,
203
204
  },
204
205
  // Beyond just specifying the plugin, additional configuration is necessary to make the plugin
@@ -282,14 +283,16 @@ export const baseImportX = tseslint.config({
282
283
  "eslint.config.mts",
283
284
  ],
284
285
  rules: {
285
- // ESLint configuration files that use "complete-lint" have a false positive with
286
- // "import-x/no-extraneous-dependencies".
286
+ // TypeScript projects that use "complete-lint" have a false positive when importing
287
+ // "defineConfig" from "eslint/config", because "eslint" is a transitive dependency in
288
+ // "complete-lint". Similarly, importing "completeConfigBase" from "eslint-config-complete"
289
+ // fails, because "eslint-config-complete" is a transitive dependency in "complete-lint".
287
290
  "import-x/no-extraneous-dependencies": [
288
291
  "warn",
289
292
  {
290
293
  devDependencies: ["**/eslint.config.{js,cjs,mjs,ts,cts,mts}"],
291
294
  optionalDependencies: false,
292
- whitelist: ["eslint-config-complete", "typescript-eslint"],
295
+ whitelist: ["eslint", "eslint-config-complete"],
293
296
  },
294
297
  ],
295
298
  // ESLint configuration files in monorepos often intentionally import from the "packages"
@@ -2,5 +2,5 @@
2
2
  * This ESLint config only contains rules from `eslint-plugin-jsdoc`:
3
3
  * https://github.com/gajus/eslint-plugin-jsdoc
4
4
  */
5
- export const baseJSDoc: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
5
+ export const baseJSDoc: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
6
6
  //# sourceMappingURL=base-jsdoc.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-jsdoc.d.ts","sourceRoot":"","sources":["../../src/base/base-jsdoc.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,4FAqQE"}
1
+ {"version":3,"file":"base-jsdoc.d.ts","sourceRoot":"","sources":["../../src/base/base-jsdoc.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,8FAqQE"}
@@ -1,10 +1,10 @@
1
1
  import ESLintPluginJSDoc from "eslint-plugin-jsdoc";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * This ESLint config only contains rules from `eslint-plugin-jsdoc`:
5
5
  * https://github.com/gajus/eslint-plugin-jsdoc
6
6
  */
7
- export const baseJSDoc = tseslint.config({
7
+ export const baseJSDoc = defineConfig({
8
8
  plugins: {
9
9
  jsdoc: ESLintPluginJSDoc,
10
10
  },
@@ -3,5 +3,5 @@
3
3
  * https://github.com/eslint-community/eslint-plugin-n
4
4
  * (This is a forked version of `eslint-plugin-node`.)
5
5
  */
6
- export const baseN: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
6
+ export const baseN: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
7
7
  //# sourceMappingURL=base-n.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-n.d.ts","sourceRoot":"","sources":["../../src/base/base-n.js"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,wFAqIG"}
1
+ {"version":3,"file":"base-n.d.ts","sourceRoot":"","sources":["../../src/base/base-n.js"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,0FAqIG"}
@@ -1,11 +1,11 @@
1
1
  import ESLintPluginN from "eslint-plugin-n";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * This ESLint config only contains rules from `eslint-plugin-n`:
5
5
  * https://github.com/eslint-community/eslint-plugin-n
6
6
  * (This is a forked version of `eslint-plugin-node`.)
7
7
  */
8
- export const baseN = tseslint.config({
8
+ export const baseN = defineConfig({
9
9
  plugins: {
10
10
  n: ESLintPluginN,
11
11
  },
@@ -0,0 +1,6 @@
1
+ /**
2
+ * This ESLint config only contains rules from `eslint-plugin-package-json`:
3
+ * https://github.com/JoshuaKGoldberg/eslint-plugin-package-json
4
+ */
5
+ export const basePackageJSON: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
6
+ //# sourceMappingURL=base-package-json.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base-package-json.d.ts","sourceRoot":"","sources":["../../src/base/base-package-json.js"],"names":[],"mappings":"AAIA;;;GAGG;AACH,oGA6GG"}
@@ -0,0 +1,92 @@
1
+ import ESLintPluginPackageJSON from "eslint-plugin-package-json";
2
+ import { defineConfig } from "eslint/config";
3
+ import * as parserJsonc from "jsonc-eslint-parser";
4
+ /**
5
+ * This ESLint config only contains rules from `eslint-plugin-package-json`:
6
+ * https://github.com/JoshuaKGoldberg/eslint-plugin-package-json
7
+ */
8
+ export const basePackageJSON = defineConfig({
9
+ plugins: {
10
+ // @ts-expect-error https://github.com/JoshuaKGoldberg/eslint-plugin-package-json/issues/1242
11
+ "package-json": ESLintPluginPackageJSON,
12
+ },
13
+ files: ["**/package.json"],
14
+ languageOptions: {
15
+ parser: parserJsonc,
16
+ parserOptions: {
17
+ extraFileExtensions: [".json"],
18
+ },
19
+ },
20
+ rules: {
21
+ "package-json/no-empty-fields": "warn",
22
+ "package-json/no-redundant-files": "warn",
23
+ /** Disabled since it is handled by `prettier-plugin-packagejson`. */
24
+ "package-json/order-properties": "off",
25
+ "package-json/repository-shorthand": "warn",
26
+ /**
27
+ * Disabled since it is only needed for public npm packages, which is too specific for this
28
+ * config.
29
+ */
30
+ "package-json/require-author": "off",
31
+ /**
32
+ * Disabled since it is only needed for public npm packages, which is too specific for this
33
+ * config.
34
+ */
35
+ "package-json/require-bugs": "off",
36
+ /** Disabled since most projects do not use `bundleDependencies`. */
37
+ "package-json/require-bundleDependencies": "off",
38
+ /** Disabled since not all projects have `dependencies`. */
39
+ "package-json/require-dependencies": "off",
40
+ "package-json/require-description": "warn",
41
+ /** Disabled since not all projects have `devDependencies`. */
42
+ "package-json/require-devDependencies": "off",
43
+ /** Disabled since not all projects have engine version constraints. */
44
+ "package-json/require-engines": "off",
45
+ /**
46
+ * Disabled since it is only needed for public npm packages, which is too specific for this
47
+ * config.
48
+ */
49
+ "package-json/require-files": "off",
50
+ /**
51
+ * Disabled since it is only needed for public npm packages, which is too specific for this
52
+ * config.
53
+ */
54
+ "package-json/require-keywords": "off",
55
+ "package-json/require-name": "warn",
56
+ /** Disabled since not all projects have `optionalDependencies`. */
57
+ "package-json/require-optionalDependencies": "off",
58
+ /** Disabled since not all projects have `peerDependencies`. */
59
+ "package-json/require-peerDependencies": "off",
60
+ "package-json/require-type": "warn",
61
+ /** Disabled since this is only needed for libraries. */
62
+ "package-json/require-types": "off",
63
+ /** Disabled since some private packages may not use versioning. */
64
+ "package-json/require-version": "off",
65
+ /** Disabled since this is supposed to be a project-specific rule. */
66
+ "package-json/restrict-dependency-ranges": "off",
67
+ /** Disabled since it is handled by `prettier-plugin-packagejson`. */
68
+ "package-json/sort-collections": "off",
69
+ "package-json/unique-dependencies": "warn",
70
+ "package-json/valid-author": "warn",
71
+ "package-json/valid-bin": "warn",
72
+ "package-json/valid-bundleDependencies": "warn",
73
+ "package-json/valid-config": "warn",
74
+ "package-json/valid-cpu": "warn",
75
+ "package-json/valid-dependencies": "warn",
76
+ "package-json/valid-description": "warn",
77
+ "package-json/valid-devDependencies": "warn",
78
+ "package-json/valid-directories": "warn",
79
+ "package-json/valid-exports": "warn",
80
+ "package-json/valid-license": "warn",
81
+ /** Disabled since the rule is deprecated. */
82
+ "package-json/valid-local-dependency": "off",
83
+ "package-json/valid-name": "warn",
84
+ "package-json/valid-optionalDependencies": "warn",
85
+ "package-json/valid-package-definition": "warn",
86
+ "package-json/valid-peerDependencies": "warn",
87
+ "package-json/valid-repository-directory": "warn",
88
+ "package-json/valid-scripts": "warn",
89
+ "package-json/valid-type": "warn",
90
+ "package-json/valid-version": "warn",
91
+ },
92
+ });
@@ -2,5 +2,5 @@
2
2
  * This ESLint config only contains rules from `@stylistic/eslint-plugin`:
3
3
  * https://eslint.style/
4
4
  */
5
- export const baseStylistic: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
5
+ export const baseStylistic: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
6
6
  //# sourceMappingURL=base-stylistic.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-stylistic.d.ts","sourceRoot":"","sources":["../../src/base/base-stylistic.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,gGA2CG"}
1
+ {"version":3,"file":"base-stylistic.d.ts","sourceRoot":"","sources":["../../src/base/base-stylistic.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,kGA2CG"}
@@ -1,10 +1,10 @@
1
1
  import ESLintPluginStylistic from "@stylistic/eslint-plugin";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * This ESLint config only contains rules from `@stylistic/eslint-plugin`:
5
5
  * https://eslint.style/
6
6
  */
7
- export const baseStylistic = tseslint.config({
7
+ export const baseStylistic = defineConfig({
8
8
  plugins: {
9
9
  "@stylistic": ESLintPluginStylistic,
10
10
  },
@@ -2,5 +2,5 @@
2
2
  * This ESLint config only contains rules from `@typescript-eslint/eslint-plugin`:
3
3
  * https://typescript-eslint.io/rules/
4
4
  */
5
- export const baseTypeScriptESLint: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
5
+ export const baseTypeScriptESLint: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
6
6
  //# sourceMappingURL=base-typescript-eslint.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-typescript-eslint.d.ts","sourceRoot":"","sources":["../../src/base/base-typescript-eslint.js"],"names":[],"mappings":"AAEA;;;GAGG;AACH,uGAsjBE"}
1
+ {"version":3,"file":"base-typescript-eslint.d.ts","sourceRoot":"","sources":["../../src/base/base-typescript-eslint.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,yGA0jBE"}
@@ -1,9 +1,10 @@
1
+ import { defineConfig } from "eslint/config";
1
2
  import tseslint from "typescript-eslint";
2
3
  /**
3
4
  * This ESLint config only contains rules from `@typescript-eslint/eslint-plugin`:
4
5
  * https://typescript-eslint.io/rules/
5
6
  */
6
- export const baseTypeScriptESLint = tseslint.config({
7
+ export const baseTypeScriptESLint = defineConfig({
7
8
  plugins: {
8
9
  "@typescript-eslint": tseslint.plugin,
9
10
  },
@@ -450,6 +451,9 @@ export const baseTypeScriptESLint = tseslint.config({
450
451
  "@typescript-eslint/unified-signatures": "warn",
451
452
  "@typescript-eslint/use-unknown-in-catch-callback-variable": "warn",
452
453
  },
454
+ // Having TypeScript rules apply to ".json" files will throw an error about needing type
455
+ // information.
456
+ ignores: ["*.json"],
453
457
  },
454
458
  // Enable linting on TypeScript file extensions.
455
459
  {
@@ -2,5 +2,5 @@
2
2
  * This ESLint config only contains rules from `eslint-plugin-unicorn`:
3
3
  * https://github.com/sindresorhus/eslint-plugin-unicorn
4
4
  */
5
- export const baseUnicorn: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
5
+ export const baseUnicorn: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
6
6
  //# sourceMappingURL=base-unicorn.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base-unicorn.d.ts","sourceRoot":"","sources":["../../src/base/base-unicorn.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,8FA8LG"}
1
+ {"version":3,"file":"base-unicorn.d.ts","sourceRoot":"","sources":["../../src/base/base-unicorn.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,gGAkMG"}
@@ -1,10 +1,10 @@
1
1
  import ESLintPluginUnicorn from "eslint-plugin-unicorn";
2
- import tseslint from "typescript-eslint";
2
+ import { defineConfig } from "eslint/config";
3
3
  /**
4
4
  * This ESLint config only contains rules from `eslint-plugin-unicorn`:
5
5
  * https://github.com/sindresorhus/eslint-plugin-unicorn
6
6
  */
7
- export const baseUnicorn = tseslint.config({
7
+ export const baseUnicorn = defineConfig({
8
8
  plugins: {
9
9
  unicorn: ESLintPluginUnicorn,
10
10
  },
@@ -33,6 +33,7 @@ export const baseUnicorn = tseslint.config({
33
33
  * single "eslint-disable" comment to make things more concise.
34
34
  */
35
35
  "unicorn/no-abusive-eslint-disable": "off",
36
+ "unicorn/no-array-sort": "warn",
36
37
  "unicorn/no-accessor-recursion": "warn",
37
38
  "unicorn/no-anonymous-default-export": "warn",
38
39
  /** Disabled since it is not helpful when using TypeScript. */
@@ -103,8 +104,10 @@ export const baseUnicorn = tseslint.config({
103
104
  "unicorn/prefer-array-index-of": "warn",
104
105
  "unicorn/prefer-array-some": "warn",
105
106
  "unicorn/prefer-at": "warn",
107
+ "unicorn/prefer-bigint-literals": "warn",
106
108
  "unicorn/prefer-blob-reading-methods": "warn",
107
109
  "unicorn/prefer-class-fields": "warn",
110
+ "unicorn/prefer-classlist-toggle": "warn",
108
111
  "unicorn/prefer-code-point": "warn",
109
112
  "unicorn/prefer-date-now": "warn",
110
113
  "unicorn/prefer-default-parameters": "warn",
@@ -154,6 +157,7 @@ export const baseUnicorn = tseslint.config({
154
157
  "unicorn/prevent-abbreviations": "off",
155
158
  "unicorn/relative-url-style": "warn",
156
159
  "unicorn/require-array-join-separator": "warn",
160
+ "unicorn/require-module-attributes": "warn",
157
161
  "unicorn/require-module-specifiers": "warn",
158
162
  "unicorn/require-number-to-fixed-digits-argument": "warn",
159
163
  /** Disabled since it is not recommended by the plugin authors. */
package/dist/base.d.ts CHANGED
@@ -4,5 +4,5 @@
4
4
  * Rule modifications are split out into different files for better organization (based on the
5
5
  * originating plugin) .
6
6
  */
7
- export const completeConfigBase: import("@typescript-eslint/utils/ts-eslint").FlatConfig.ConfigArray;
7
+ export const completeConfigBase: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
8
8
  //# sourceMappingURL=base.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../src/base.js"],"names":[],"mappings":"AAUA;;;;;GAKG;AACH,qGA0BE"}
1
+ {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../src/base.js"],"names":[],"mappings":"AAWA;;;;;GAKG;AACH,uGA2BE"}
package/dist/base.js CHANGED
@@ -1,9 +1,10 @@
1
- import tseslint from "typescript-eslint";
1
+ import { defineConfig } from "eslint/config";
2
2
  import { baseComplete } from "./base/base-complete.js";
3
3
  import { baseESLint } from "./base/base-eslint.js";
4
4
  import { baseImportX } from "./base/base-import-x.js";
5
5
  import { baseJSDoc } from "./base/base-jsdoc.js";
6
6
  import { baseN } from "./base/base-n.js";
7
+ import { basePackageJSON } from "./base/base-package-json.js";
7
8
  import { baseStylistic } from "./base/base-stylistic.js";
8
9
  import { baseTypeScriptESLint } from "./base/base-typescript-eslint.js";
9
10
  import { baseUnicorn } from "./base/base-unicorn.js";
@@ -13,8 +14,8 @@ import { baseUnicorn } from "./base/base-unicorn.js";
13
14
  * Rule modifications are split out into different files for better organization (based on the
14
15
  * originating plugin) .
15
16
  */
16
- export const completeConfigBase = tseslint.config(...baseESLint, ...baseTypeScriptESLint, ...baseStylistic, ...baseImportX, ...baseJSDoc, ...baseN, // "n" stands for Node.
17
- ...baseUnicorn, ...baseComplete,
17
+ export const completeConfigBase = defineConfig(...baseESLint, ...baseTypeScriptESLint, ...baseStylistic, ...baseImportX, ...baseJSDoc, ...baseN, // "n" stands for Node.
18
+ ...basePackageJSON, ...baseUnicorn, ...baseComplete,
18
19
  // We prefer the official `reportUnusedDisableDirectives` linter option over the 3rd-party plugin
19
20
  // of "eslint-plugin-eslint-comments".
20
21
  {
@@ -0,0 +1,8 @@
1
+ /**
2
+ * This ESLint config is meant to be used as a base for all TypeScript projects.
3
+ *
4
+ * Rule modifications are split out into different files for better organization (based on the
5
+ * originating plugin) .
6
+ */
7
+ export const completeConfigESLintPlugin: import("eslint").Linter.Config<import("eslint").Linter.RulesRecord>[];
8
+ //# sourceMappingURL=eslint-plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"eslint-plugin.d.ts","sourceRoot":"","sources":["../src/eslint-plugin.js"],"names":[],"mappings":"AAGA;;;;;GAKG;AACH,+GA4DG"}
@@ -0,0 +1,63 @@
1
+ import ESLintPluginESLintPlugin from "eslint-plugin-eslint-plugin";
2
+ import { defineConfig } from "eslint/config";
3
+ /**
4
+ * This ESLint config is meant to be used as a base for all TypeScript projects.
5
+ *
6
+ * Rule modifications are split out into different files for better organization (based on the
7
+ * originating plugin) .
8
+ */
9
+ export const completeConfigESLintPlugin = defineConfig({
10
+ plugins: {
11
+ "eslint-plugin": ESLintPluginESLintPlugin,
12
+ },
13
+ rules: {
14
+ "eslint-plugin/consistent-output": "warn",
15
+ "eslint-plugin/fixer-return": "warn",
16
+ "eslint-plugin/meta-property-ordering": "warn",
17
+ "eslint-plugin/no-deprecated-context-methods": "warn",
18
+ "eslint-plugin/no-deprecated-report-api": "warn",
19
+ "eslint-plugin/no-identical-tests": "warn",
20
+ "eslint-plugin/no-meta-replaced-by": "warn",
21
+ "eslint-plugin/no-meta-schema-default": "warn",
22
+ "eslint-plugin/no-missing-message-ids": "warn",
23
+ "eslint-plugin/no-missing-placeholders": "warn",
24
+ "eslint-plugin/no-only-tests": "warn",
25
+ "eslint-plugin/no-property-in-node": "warn",
26
+ "eslint-plugin/no-unused-message-ids": "warn",
27
+ "eslint-plugin/no-unused-placeholders": "warn",
28
+ "eslint-plugin/no-useless-token-range": "warn",
29
+ "eslint-plugin/prefer-message-ids": "warn",
30
+ "eslint-plugin/prefer-object-rule": "warn",
31
+ "eslint-plugin/prefer-output-null": "warn",
32
+ "eslint-plugin/prefer-placeholders": "warn",
33
+ "eslint-plugin/prefer-replace-text": "warn",
34
+ "eslint-plugin/report-message-format": "warn",
35
+ /**
36
+ * TODO: Enable this rule.
37
+ *
38
+ * @see https://github.com/eslint-community/eslint-plugin-eslint-plugin/issues/545
39
+ */
40
+ "eslint-plugin/require-meta-default-options": "off",
41
+ /**
42
+ * TODO: Remove these options.
43
+ *
44
+ * @see https://github.com/eslint-community/eslint-plugin-eslint-plugin/pull/495
45
+ */
46
+ "eslint-plugin/require-meta-docs-description": [
47
+ "warn",
48
+ {
49
+ pattern: "^(Enforce|Require|Disallow)",
50
+ },
51
+ ],
52
+ "eslint-plugin/require-meta-docs-recommended": "warn",
53
+ /** Disabled since this is automatically handled by the `createRule` helper function. */
54
+ "eslint-plugin/require-meta-docs-url": "off",
55
+ "eslint-plugin/require-meta-fixable": "warn",
56
+ "eslint-plugin/require-meta-has-suggestions": "warn",
57
+ "eslint-plugin/require-meta-schema": "warn",
58
+ "eslint-plugin/require-meta-schema-description": "warn",
59
+ "eslint-plugin/require-meta-type": "warn",
60
+ "eslint-plugin/test-case-property-ordering": "warn",
61
+ "eslint-plugin/test-case-shorthand-strings": "warn",
62
+ },
63
+ });
package/dist/index.d.ts CHANGED
@@ -1,2 +1,3 @@
1
1
  export { completeConfigBase } from "./base.js";
2
+ export { completeConfigESLintPlugin } from "./eslint-plugin.js";
2
3
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -1 +1,2 @@
1
1
  export { completeConfigBase } from "./base.js";
2
+ export { completeConfigESLintPlugin } from "./eslint-plugin.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-config-complete",
3
- "version": "2.1.0",
3
+ "version": "2.1.2",
4
4
  "description": "A sharable ESLint config for TypeScript projects.",
5
5
  "keywords": [
6
6
  "eslint",
@@ -24,9 +24,6 @@
24
24
  "main": "./dist/index.js",
25
25
  "types": "./dist/index.d.ts",
26
26
  "files": [
27
- "LICENSE",
28
- "package.json",
29
- "README.md",
30
27
  "dist"
31
28
  ],
32
29
  "scripts": {
@@ -35,25 +32,31 @@
35
32
  "lint": "tsx ./scripts/lint.ts"
36
33
  },
37
34
  "dependencies": {
38
- "@stylistic/eslint-plugin": "5.2.2",
35
+ "@stylistic/eslint-plugin": "5.3.1",
39
36
  "confusing-browser-globals": "1.0.11",
40
37
  "eslint-import-resolver-typescript": "4.4.4",
41
- "eslint-plugin-complete": "1.1.1",
38
+ "eslint-plugin-complete": "1.1.2",
39
+ "eslint-plugin-eslint-plugin": "7.0.0",
42
40
  "eslint-plugin-import-x": "4.16.1",
43
- "eslint-plugin-jsdoc": "52.0.4",
41
+ "eslint-plugin-jsdoc": "55.0.3",
44
42
  "eslint-plugin-n": "17.21.3",
45
- "eslint-plugin-unicorn": "60.0.0",
46
- "typescript-eslint": "8.39.0"
43
+ "eslint-plugin-package-json": "0.56.2",
44
+ "eslint-plugin-unicorn": "61.0.2",
45
+ "jsonc-eslint-parser": "2.4.0",
46
+ "typescript-eslint": "8.43.0"
47
47
  },
48
48
  "devDependencies": {
49
- "@eslint/js": "9.32.0",
49
+ "@eslint/js": "9.35.0",
50
50
  "@types/confusing-browser-globals": "1.0.3",
51
51
  "@types/eslint-config-prettier": "6.11.3",
52
- "@types/node": "24.2.0",
52
+ "@types/node": "24.3.1",
53
53
  "complete-common": "2.5.0",
54
- "complete-node": "8.0.0",
54
+ "complete-node": "9.3.3",
55
55
  "eslint-config-prettier": "10.1.8",
56
56
  "extract-comments": "1.1.0",
57
57
  "typescript": "5.9.2"
58
+ },
59
+ "peerDependencies": {
60
+ "eslint": ">= 9.0.0"
58
61
  }
59
62
  }