eslint-config-complete 4.0.0 → 4.1.1

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.
@@ -1 +1 @@
1
- {"version":3,"file":"base-eslint.d.ts","sourceRoot":"","sources":["../../src/base/base-eslint.js"],"names":[],"mappings":"AA6mBA;;;;;;;;GAQG;AACH,0DAMG"}
1
+ {"version":3,"file":"base-eslint.d.ts","sourceRoot":"","sources":["../../src/base/base-eslint.js"],"names":[],"mappings":"AA2pBA;;;;;;;;GAQG;AACH,0DAMG"}
@@ -12,23 +12,30 @@ const POSSIBLE_PROBLEMS = {
12
12
  checkForEach: true,
13
13
  },
14
14
  ],
15
+ /** Disabled since this is already enforced by TypeScript (`ts(2335)` & `ts(2377)`). */
15
16
  "constructor-super": "off", // @typescript-eslint/eslint-recommended
16
17
  "for-direction": "error",
18
+ /** Disabled since this is already enforced by TypeScript (`ts(2378)`). */
17
19
  "getter-return": "off", // @typescript-eslint/eslint-recommended
18
20
  "no-async-promise-executor": "error",
19
21
  "no-await-in-loop": "error",
22
+ /** Disabled since this is already enforced by TypeScript (`ts(2629)`). */
20
23
  "no-class-assign": "error",
21
24
  "no-compare-neg-zero": "error",
22
25
  "no-cond-assign": "error",
26
+ /** Disabled since this is already enforced by TypeScript (`ts(2588)`). */
23
27
  "no-const-assign": "off", // @typescript-eslint/eslint-recommended
24
28
  "no-constant-binary-expression": "error",
25
29
  "no-constant-condition": "error",
26
30
  "no-constructor-return": "error",
27
31
  "no-control-regex": "error",
28
32
  "no-debugger": "error",
33
+ /** Disabled since this is already enforced by TypeScript (`ts(2300)`). */
29
34
  "no-dupe-args": "off", // @typescript-eslint/eslint-recommended
35
+ /** Disabled since this is already enforced by TypeScript (`ts(2393)` & `ts(2300)`). */
30
36
  "no-dupe-class-members": "off", // @typescript-eslint/eslint-recommended
31
37
  "no-dupe-else-if": "error",
38
+ /** Disabled since this is already enforced by TypeScript (`ts(1117)`). */
32
39
  "no-dupe-keys": "off", // @typescript-eslint/eslint-recommended
33
40
  "no-duplicate-case": "error",
34
41
  /** Superseded by the `import-x/no-duplicates` rule. */
@@ -37,7 +44,9 @@ const POSSIBLE_PROBLEMS = {
37
44
  "no-empty-pattern": "error",
38
45
  "no-ex-assign": "error",
39
46
  "no-fallthrough": "error",
47
+ /** Disabled since this is already enforced by TypeScript (`ts(2630)`). */
40
48
  "no-func-assign": "off", // @typescript-eslint/eslint-recommended
49
+ /** Disabled since this is already enforced by TypeScript (`ts(2632)` & `ts(2540)`). */
41
50
  "no-import-assign": "off", // @typescript-eslint/eslint-recommended
42
51
  "no-inner-declarations": "error",
43
52
  "no-invalid-regexp": "error",
@@ -45,24 +54,33 @@ const POSSIBLE_PROBLEMS = {
45
54
  /** Superseded by the `@typescript-eslint/no-loss-of-precision` rule. */
46
55
  "no-loss-of-precision": "off",
47
56
  "no-misleading-character-class": "error",
48
- "no-new-native-nonconstructor": "error",
57
+ /** Disabled since this is already enforced by TypeScript (`ts(7009)`). */
58
+ "no-new-native-nonconstructor": "off", // @typescript-eslint/eslint-recommended
59
+ /** Disabled since this is already enforced by TypeScript (`ts(2349)`). */
49
60
  "no-obj-calls": "off", // @typescript-eslint/eslint-recommended`
50
61
  "no-promise-executor-return": "error",
51
62
  "no-prototype-builtins": "error",
52
63
  "no-self-assign": "error",
53
64
  "no-self-compare": "error",
65
+ /** Disabled since this is already enforced by TypeScript (`ts(2408)`). */
54
66
  "no-setter-return": "off", // @typescript-eslint/eslint-recommended
55
67
  "no-sparse-arrays": "error",
56
68
  /** Superseded by the `complete/eqeqeq-fix` rule (since we want auto-fix to work properly). */
57
69
  "no-template-curly-in-string": "off",
70
+ /** Disabled since this is already enforced by TypeScript (`ts(2376)` & `ts(17009)`). */
58
71
  "no-this-before-super": "off", // @typescript-eslint/eslint-recommended`
59
72
  "no-unassigned-vars": "error",
73
+ /** Disabled since this is already enforced by TypeScript (`ts(2304)` & `ts(2552)`). */
60
74
  "no-undef": "off", // @typescript-eslint/eslint-recommended
61
75
  "no-unexpected-multiline": "off", // eslint-config-prettier
62
76
  "no-unmodified-loop-condition": "error",
77
+ /** Disabled since this is already enforced by TypeScript (`ts(7027)`). */
63
78
  "no-unreachable": "off", // @typescript-eslint/eslint-recommended
64
79
  "no-unreachable-loop": "error",
65
80
  "no-unsafe-finally": "error",
81
+ /**
82
+ * Disabled since this is already enforced by TypeScript (`ts(2365)` & `ts(2322)` & `ts(2358)`).
83
+ */
66
84
  "no-unsafe-negation": "off", // @typescript-eslint/eslint-recommended
67
85
  "no-unsafe-optional-chaining": "error",
68
86
  "no-unused-private-class-members": "error",
@@ -276,8 +294,8 @@ const SUGGESTIONS = {
276
294
  */
277
295
  "no-plusplus": "off",
278
296
  "no-proto": "error",
279
- /** Superseded by the `@typescript-eslint/block-spacing` rule. */
280
- "no-redeclare": "off",
297
+ /** Disabled since this is already enforced by TypeScript (`ts(2451)`). */
298
+ "no-redeclare": "off", // @typescript-eslint/eslint-recommended
281
299
  "no-regex-spaces": "error",
282
300
  /**
283
301
  * The options are [copied from
@@ -429,7 +447,8 @@ const SUGGESTIONS = {
429
447
  "no-void": "error",
430
448
  /** Superseded by the `unicorn/expiring-todo-comments` rule. */
431
449
  "no-warning-comments": "off",
432
- "no-with": "error",
450
+ /** Disabled since this is already enforced by TypeScript (`ts(1101)` & `ts(2410)`). */
451
+ "no-with": "off", // @typescript-eslint/eslint-recommended
433
452
  /** The `ignoreConstructors` option is disabled to make the rule stricter. */
434
453
  "object-shorthand": [
435
454
  "error",
@@ -1 +1 @@
1
- {"version":3,"file":"base-import-x.d.ts","sourceRoot":"","sources":["../../src/base/base-import-x.js"],"names":[],"mappings":"AA+NA;;;;;;;;;GASG;AACH,2DAuFE"}
1
+ {"version":3,"file":"base-import-x.d.ts","sourceRoot":"","sources":["../../src/base/base-import-x.js"],"names":[],"mappings":"AA8NA;;;;;;;;;GASG;AACH,2DAuFE"}
@@ -19,8 +19,6 @@ const HELPFUL_WARNINGS = {
19
19
  devDependencies: [
20
20
  // From:
21
21
  // https://github.com/airbnb/javascript/blob/master/packages/eslint-config-airbnb-base/rules/imports.js
22
- "test/**", // tape, common npm pattern
23
- "tests/**", // also common npm pattern
24
22
  "spec/**", // mocha, rspec-like pattern
25
23
  "**/__tests__/**", // jest pattern
26
24
  "**/__mocks__/**", // jest pattern
@@ -33,8 +31,9 @@ const HELPFUL_WARNINGS = {
33
31
  "**/protractor.conf.js", // protractor config
34
32
  "**/protractor.conf.*.js", // protractor config
35
33
  "**/karma.conf.js", // karma config
36
- "**/scripts/**/*.{js,cjs,mjs,ts,cts,mts}", // Files inside of a "scripts" directory.
37
- "**/tests/**/*.{js,cjs,mjs,ts,cts,mts}", // Files inside of a "tests" directory.
34
+ "**/scripts/**", // Files inside of a "scripts" directory.
35
+ "**/test/**", // Files inside of a "test" directory.
36
+ "**/tests/**", // Files inside of a "tests" directory.
38
37
  "**/*.config.{js,cjs,mjs,ts,cts,mts}", // Config files like "eslint.config.mjs"
39
38
  "**/*.config.*.{js,cjs,mjs,ts,cts,mts}", // Config files like "eslint.config.json.mjs"
40
39
  ],
@@ -1 +1 @@
1
- {"version":3,"file":"base-jsdoc.d.ts","sourceRoot":"","sources":["../../src/base/base-jsdoc.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,yDAqSE"}
1
+ {"version":3,"file":"base-jsdoc.d.ts","sourceRoot":"","sources":["../../src/base/base-jsdoc.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,yDAwSE"}
@@ -36,7 +36,7 @@ export const baseJSDoc = defineConfig({
36
36
  definedTags: [
37
37
  // Ignore tags used by the TypeScript compiler:
38
38
  // https://www.typescriptlang.org/tsconfig#stripInternal
39
- "internal", // Used by TypeScript
39
+ "internal",
40
40
  // Ignore tags used in TypeDoc:
41
41
  // https://typedoc.org/guides/doccomments/
42
42
  "category",
@@ -181,6 +181,8 @@ export const baseJSDoc = defineConfig({
181
181
  "jsdoc/require-property-name": "error",
182
182
  /** Disabled because it is not needed in TypeScript. */
183
183
  "jsdoc/require-property-type": "off",
184
+ /** Disabled because it is overboard to document every throw statement. */
185
+ "jsdoc/require-rejects": "off",
184
186
  /** Disabled because it is overboard for every function to document every return value. */
185
187
  "jsdoc/require-returns": "off",
186
188
  /** Disabled because it is overboard for every function to document every return value. */
@@ -1 +1 @@
1
- {"version":3,"file":"base-stylistic.d.ts","sourceRoot":"","sources":["../../src/base/base-stylistic.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,6DA2CG"}
1
+ {"version":3,"file":"base-stylistic.d.ts","sourceRoot":"","sources":["../../src/base/base-stylistic.js"],"names":[],"mappings":"AAGA;;;GAGG;AACH,6DAiDG"}
@@ -17,6 +17,11 @@ export const baseStylistic = defineConfig({
17
17
  exceptAfterSingleLine: true,
18
18
  },
19
19
  ],
20
+ /** Enforce a blank line between functions. (Prettier does not do this by default.) */
21
+ "@stylistic/padding-line-between-statements": [
22
+ "error",
23
+ { blankLine: "always", prev: "function", next: "function" },
24
+ ],
20
25
  /**
21
26
  * We forbid unnecessary backticks by using the options specified in [the
22
27
  * `eslint-config-prettier`
@@ -1 +1 @@
1
- {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../src/base.js"],"names":[],"mappings":"AAUA;;;;;GAKG;AACH,kEAkBE"}
1
+ {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../src/base.js"],"names":[],"mappings":"AAUA;;;;;GAKG;AACH,kEAsBE"}
package/dist/base.js CHANGED
@@ -13,7 +13,11 @@ import { baseUnicorn } from "./base/base-unicorn.js";
13
13
  * Rule modifications are split out into different files for better organization (based on the
14
14
  * originating plugin) .
15
15
  */
16
- export const completeConfigBase = defineConfig(...baseESLint, ...baseTypeScriptESLint, ...baseStylistic, ...baseImportX, ...baseJSDoc, ...baseN, // "n" stands for Node.
16
+ export const completeConfigBase = defineConfig(
17
+ // By default, ESLint will include ".js", ".cjs", and ".mjs" file extensions:
18
+ // https://eslint.org/docs/latest/use/configure/configuration-files#specifying-files-and-ignores
19
+ // TypeScript file extensions are enabled in the "base-typescript-eslint.js" file.
20
+ ...baseESLint, ...baseTypeScriptESLint, ...baseStylistic, ...baseImportX, ...baseJSDoc, ...baseN, // "n" stands for Node.
17
21
  ...baseUnicorn, ...baseComplete, {
18
22
  // By default, ESLint ignores "**/node_modules/" and ".git/":
19
23
  // https://eslint.org/docs/latest/use/configure/ignore#ignoring-files
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-config-complete",
3
- "version": "4.0.0",
3
+ "version": "4.1.1",
4
4
  "description": "A sharable ESLint config for TypeScript projects.",
5
5
  "keywords": [
6
6
  "eslint",
@@ -32,25 +32,25 @@
32
32
  "lint": "tsx ./scripts/lint.ts"
33
33
  },
34
34
  "dependencies": {
35
- "@stylistic/eslint-plugin": "5.6.0",
35
+ "@stylistic/eslint-plugin": "5.6.1",
36
36
  "confusing-browser-globals": "1.0.11",
37
37
  "eslint-import-resolver-typescript": "4.4.4",
38
38
  "eslint-plugin-complete": "1.1.3",
39
39
  "eslint-plugin-eslint-plugin": "7.2.0",
40
40
  "eslint-plugin-import-x": "4.16.1",
41
- "eslint-plugin-jsdoc": "61.2.1",
41
+ "eslint-plugin-jsdoc": "61.4.1",
42
42
  "eslint-plugin-n": "17.23.1",
43
43
  "eslint-plugin-unicorn": "62.0.0",
44
44
  "jsonc-eslint-parser": "2.4.1",
45
- "typescript-eslint": "8.47.0"
45
+ "typescript-eslint": "8.48.0"
46
46
  },
47
47
  "devDependencies": {
48
48
  "@eslint/js": "9.39.1",
49
49
  "@types/confusing-browser-globals": "1.0.3",
50
50
  "@types/eslint-config-prettier": "6.11.3",
51
51
  "@types/node": "24.10.1",
52
- "complete-common": "2.9.0",
53
- "complete-node": "12.2.1",
52
+ "complete-common": "2.10.0",
53
+ "complete-node": "12.4.2",
54
54
  "eslint-config-prettier": "10.1.8",
55
55
  "extract-comments": "1.1.0",
56
56
  "typescript": "5.9.3"