@pumpn/eslint-config 15.6.1 → 16.0.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.
- package/config.js +0 -57
- package/deno.json +8 -8
- package/deno.lock +6 -4005
- package/package.json +18 -19
- package/plugins.js +2 -4
- package/rules/_exports.js +1 -1
- package/rules/command.js +12 -0
- package/rules/import-x/style-guide.js +1 -6
- package/rules/jsdoc.js +1 -1
- package/rules/perfectionist.js +11 -2
- package/rules/unicorn.js +5 -0
- package/.tool-versions +0 -1
- package/rules/func-params-args.js +0 -19
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pumpn/eslint-config",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "16.0.0",
|
|
4
4
|
"description": "standard eslint config for pumpn code projects",
|
|
5
5
|
"main": "config.js",
|
|
6
6
|
"author": "Nano Miratus <nanomiratus@gmail.com>",
|
|
@@ -17,31 +17,30 @@
|
|
|
17
17
|
"test": "echo 'no tests yet'"
|
|
18
18
|
},
|
|
19
19
|
"devDependencies": {
|
|
20
|
-
"eslint": "^9.
|
|
20
|
+
"eslint": "^9.21.0"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@eslint-community/eslint-plugin-eslint-comments": "^4.4.
|
|
24
|
-
"@eslint-react/eslint-plugin": "^1.
|
|
25
|
-
"@stylistic/eslint-plugin": "^
|
|
26
|
-
"@typescript-eslint/parser": "^8.
|
|
23
|
+
"@eslint-community/eslint-plugin-eslint-comments": "^4.4.1",
|
|
24
|
+
"@eslint-react/eslint-plugin": "^1.28.0",
|
|
25
|
+
"@stylistic/eslint-plugin": "^4.1.0",
|
|
26
|
+
"@typescript-eslint/parser": "^8.25.0",
|
|
27
|
+
"eslint-plugin-command": "^3.1.0",
|
|
27
28
|
"eslint-plugin-depend": "^0.12.0",
|
|
28
|
-
"eslint-plugin-
|
|
29
|
-
"eslint-plugin-
|
|
30
|
-
"eslint-plugin-import-x": "^4.3.1",
|
|
31
|
-
"eslint-plugin-jsdoc": "^50.4.3",
|
|
29
|
+
"eslint-plugin-import-x": "^4.6.1",
|
|
30
|
+
"eslint-plugin-jsdoc": "^50.6.3",
|
|
32
31
|
"eslint-plugin-no-secrets": "^2.2.1",
|
|
33
|
-
"eslint-plugin-perfectionist": "^4.
|
|
34
|
-
"eslint-plugin-promise": "^7.1
|
|
35
|
-
"eslint-plugin-react": "^7.
|
|
32
|
+
"eslint-plugin-perfectionist": "^4.9.0",
|
|
33
|
+
"eslint-plugin-promise": "^7.2.1",
|
|
34
|
+
"eslint-plugin-react": "^7.37.4",
|
|
36
35
|
"eslint-plugin-redos": "^4.4.5",
|
|
37
|
-
"eslint-plugin-regexp": "^2.
|
|
36
|
+
"eslint-plugin-regexp": "^2.7.0",
|
|
38
37
|
"eslint-plugin-security": "^3.0.1",
|
|
39
|
-
"eslint-plugin-sonarjs": "^3.0.
|
|
38
|
+
"eslint-plugin-sonarjs": "^3.0.2",
|
|
40
39
|
"eslint-plugin-tailwindcss": "^3.18.0",
|
|
41
|
-
"eslint-plugin-unicorn": "^
|
|
42
|
-
"globals": "^
|
|
40
|
+
"eslint-plugin-unicorn": "^57.0.0",
|
|
41
|
+
"globals": "^16.0.0"
|
|
43
42
|
},
|
|
44
43
|
"peerDependencies": {
|
|
45
|
-
"eslint": "^9.
|
|
44
|
+
"eslint": "^9.21.0"
|
|
46
45
|
}
|
|
47
|
-
}
|
|
46
|
+
}
|
package/plugins.js
CHANGED
|
@@ -8,9 +8,8 @@
|
|
|
8
8
|
import eslintComments from "@eslint-community/eslint-plugin-eslint-comments";
|
|
9
9
|
import react from "@eslint-react/eslint-plugin";
|
|
10
10
|
import stylistic from "@stylistic/eslint-plugin";
|
|
11
|
+
import command from "eslint-plugin-command";
|
|
11
12
|
import depend from "eslint-plugin-depend";
|
|
12
|
-
import disableAutofix from "eslint-plugin-disable-autofix";
|
|
13
|
-
import funcParamsArgs from "eslint-plugin-func-params-args";
|
|
14
13
|
import importX from "eslint-plugin-import-x";
|
|
15
14
|
import jsdoc from "eslint-plugin-jsdoc";
|
|
16
15
|
import noSecrets from "eslint-plugin-no-secrets";
|
|
@@ -40,9 +39,8 @@ const plugins = /** @type {const} */ ({
|
|
|
40
39
|
// "no-unsanitized": noUnsanitized,
|
|
41
40
|
"@eslint-community/eslint-comments": eslintComments,
|
|
42
41
|
"@stylistic": /** @type {ESLint.Plugin} */ (stylistic),
|
|
42
|
+
command,
|
|
43
43
|
depend,
|
|
44
|
-
"disable-autofix": disableAutofix,
|
|
45
|
-
"func-params-args": funcParamsArgs,
|
|
46
44
|
"import-x": /** @type {ESLint.Plugin} */ (
|
|
47
45
|
/** @type {unknown} */ (importX)
|
|
48
46
|
),
|
package/rules/_exports.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export { default as dependRules } from "./depend.js";
|
|
2
2
|
export { default as eslintCommentsRules } from "./eslint-comments.js";
|
|
3
|
-
export { default as funcParamsArgsRules } from "./func-params-args.js";
|
|
4
3
|
// export { default as githubRules } from "./github.js";
|
|
5
4
|
export { default as importXRules } from "./import-x.js";
|
|
6
5
|
export { default as jsdocRules } from "./jsdoc.js";
|
|
@@ -14,6 +13,7 @@ export { default as perfectionistRules } from "./perfectionist.js";
|
|
|
14
13
|
export { default as possibleProblemsRules } from "./possible-problems.js";
|
|
15
14
|
export { default as reactRules } from "./react.js";
|
|
16
15
|
// export { default as redosRules } from "./redos.js";
|
|
16
|
+
export { default as commandRules } from "./command.js";
|
|
17
17
|
export { default as regexpRules } from "./regexp.js";
|
|
18
18
|
export { default as securityRules } from "./security.js";
|
|
19
19
|
export { default as sonarjsRules } from "./sonarjs.js";
|
package/rules/command.js
ADDED
|
@@ -31,12 +31,7 @@ const styleGuideRules = {
|
|
|
31
31
|
"import-x/no-duplicates": "error",
|
|
32
32
|
"import-x/no-named-default": "error",
|
|
33
33
|
"import-x/no-named-export": "off",
|
|
34
|
-
"import-x/no-namespace":
|
|
35
|
-
"error",
|
|
36
|
-
{
|
|
37
|
-
ignore: ["{./**/,**/}_exports.?(*.)js", "@typescript-eslint/parser"]
|
|
38
|
-
}
|
|
39
|
-
],
|
|
34
|
+
"import-x/no-namespace": "off",
|
|
40
35
|
"import-x/no-unassigned-import": "error",
|
|
41
36
|
"import-x/order": [
|
|
42
37
|
"off",
|
package/rules/jsdoc.js
CHANGED
package/rules/perfectionist.js
CHANGED
|
@@ -39,7 +39,8 @@ const perfectionistRules = {
|
|
|
39
39
|
["private-method", "private-function-property"],
|
|
40
40
|
"unknown"
|
|
41
41
|
],
|
|
42
|
-
partitionByComment: String.raw
|
|
42
|
+
partitionByComment: String.raw`\/\/`,
|
|
43
|
+
partitionByNewLine: false
|
|
43
44
|
}
|
|
44
45
|
],
|
|
45
46
|
"perfectionist/sort-enums": ["error"],
|
|
@@ -97,7 +98,15 @@ const perfectionistRules = {
|
|
|
97
98
|
]
|
|
98
99
|
}
|
|
99
100
|
],
|
|
100
|
-
"perfectionist/sort-maps": [
|
|
101
|
+
"perfectionist/sort-maps": [
|
|
102
|
+
"error",
|
|
103
|
+
{
|
|
104
|
+
ignoreCase: false,
|
|
105
|
+
order: "asc",
|
|
106
|
+
partitionByNewLine: true,
|
|
107
|
+
type: "natural"
|
|
108
|
+
}
|
|
109
|
+
],
|
|
101
110
|
"perfectionist/sort-named-exports": ["error"],
|
|
102
111
|
"perfectionist/sort-named-imports": ["error", { partitionByComment: false }],
|
|
103
112
|
"perfectionist/sort-object-types": ["error"],
|
package/rules/unicorn.js
CHANGED
|
@@ -39,6 +39,8 @@ const patterns = {
|
|
|
39
39
|
*/
|
|
40
40
|
const unicornRules = {
|
|
41
41
|
"unicorn/catch-error-name": "error",
|
|
42
|
+
"unicorn/consistent-assert": "error",
|
|
43
|
+
"unicorn/consistent-date-clone": "error",
|
|
42
44
|
"unicorn/consistent-destructuring": "error",
|
|
43
45
|
"unicorn/consistent-empty-array-spread": "error",
|
|
44
46
|
"unicorn/consistent-existence-index-check": "error",
|
|
@@ -58,6 +60,7 @@ const unicornRules = {
|
|
|
58
60
|
"unicorn/import-style": "error",
|
|
59
61
|
"unicorn/new-for-builtins": "error",
|
|
60
62
|
"unicorn/no-abusive-eslint-disable": "error",
|
|
63
|
+
"unicorn/no-accessor-recursion": "error",
|
|
61
64
|
"unicorn/no-anonymous-default-export": "error",
|
|
62
65
|
"unicorn/no-array-callback-reference": "off",
|
|
63
66
|
"unicorn/no-array-for-each": "error",
|
|
@@ -72,6 +75,7 @@ const unicornRules = {
|
|
|
72
75
|
"unicorn/no-for-loop": "error",
|
|
73
76
|
"unicorn/no-hex-escape": "error",
|
|
74
77
|
"unicorn/no-instanceof-array": "error",
|
|
78
|
+
"unicorn/no-instanceof-builtins": "error",
|
|
75
79
|
"unicorn/no-invalid-fetch-options": "error",
|
|
76
80
|
"unicorn/no-invalid-remove-event-listener": "error",
|
|
77
81
|
"unicorn/no-keyword-prefix": [
|
|
@@ -84,6 +88,7 @@ const unicornRules = {
|
|
|
84
88
|
"unicorn/no-length-as-slice-end": "error",
|
|
85
89
|
"unicorn/no-lonely-if": "error",
|
|
86
90
|
"unicorn/no-magic-array-flat-depth": "error",
|
|
91
|
+
"unicorn/no-named-default": "error",
|
|
87
92
|
"unicorn/no-negated-condition": "error",
|
|
88
93
|
"unicorn/no-negation-in-equality-check": "error",
|
|
89
94
|
"unicorn/no-nested-ternary": "error",
|
package/.tool-versions
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
nodejs 22.5.1
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @import { Linter } from "eslint"
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* @satisfies {Linter.RulesRecord}
|
|
7
|
-
*/
|
|
8
|
-
const funcParamsArgsRules = {
|
|
9
|
-
"func-params-args/func-args": [
|
|
10
|
-
"warn",
|
|
11
|
-
{
|
|
12
|
-
global: 3,
|
|
13
|
-
join: -1,
|
|
14
|
-
reduce: 4
|
|
15
|
-
}
|
|
16
|
-
]
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
export default funcParamsArgsRules;
|