@pumpn/eslint-config 13.0.2 → 13.2.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.
@@ -0,0 +1,13 @@
1
+ .bd__button {
2
+ padding: 10px 0;
3
+ text-align: right;
4
+ }
5
+ .bd__button > a{
6
+ font-weight: 100;
7
+ text-decoration: none;
8
+ color: #BDC3CB;
9
+ font-family: sans-serif;
10
+ }
11
+ .bd__button > a:hover {
12
+ color: #798897;
13
+ }
@@ -0,0 +1,111 @@
1
+ /* JSDoc prettify.js theme */
2
+
3
+ /* plain text */
4
+ .pln {
5
+ color: #000000;
6
+ font-weight: normal;
7
+ font-style: normal;
8
+ }
9
+
10
+ /* string content */
11
+ .str {
12
+ color: #006400;
13
+ font-weight: normal;
14
+ font-style: normal;
15
+ }
16
+
17
+ /* a keyword */
18
+ .kwd {
19
+ color: #000000;
20
+ font-weight: bold;
21
+ font-style: normal;
22
+ }
23
+
24
+ /* a comment */
25
+ .com {
26
+ font-weight: normal;
27
+ font-style: italic;
28
+ }
29
+
30
+ /* a type name */
31
+ .typ {
32
+ color: #000000;
33
+ font-weight: normal;
34
+ font-style: normal;
35
+ }
36
+
37
+ /* a literal value */
38
+ .lit {
39
+ color: #006400;
40
+ font-weight: normal;
41
+ font-style: normal;
42
+ }
43
+
44
+ /* punctuation */
45
+ .pun {
46
+ color: #000000;
47
+ font-weight: bold;
48
+ font-style: normal;
49
+ }
50
+
51
+ /* lisp open bracket */
52
+ .opn {
53
+ color: #000000;
54
+ font-weight: bold;
55
+ font-style: normal;
56
+ }
57
+
58
+ /* lisp close bracket */
59
+ .clo {
60
+ color: #000000;
61
+ font-weight: bold;
62
+ font-style: normal;
63
+ }
64
+
65
+ /* a markup tag name */
66
+ .tag {
67
+ color: #006400;
68
+ font-weight: normal;
69
+ font-style: normal;
70
+ }
71
+
72
+ /* a markup attribute name */
73
+ .atn {
74
+ color: #006400;
75
+ font-weight: normal;
76
+ font-style: normal;
77
+ }
78
+
79
+ /* a markup attribute value */
80
+ .atv {
81
+ color: #006400;
82
+ font-weight: normal;
83
+ font-style: normal;
84
+ }
85
+
86
+ /* a declaration */
87
+ .dec {
88
+ color: #000000;
89
+ font-weight: bold;
90
+ font-style: normal;
91
+ }
92
+
93
+ /* a variable name */
94
+ .var {
95
+ color: #000000;
96
+ font-weight: normal;
97
+ font-style: normal;
98
+ }
99
+
100
+ /* a function name */
101
+ .fun {
102
+ color: #000000;
103
+ font-weight: bold;
104
+ font-style: normal;
105
+ }
106
+
107
+ /* Specify class=linenums on a pre to get line numbering */
108
+ ol.linenums {
109
+ margin-top: 0;
110
+ margin-bottom: 0;
111
+ }
@@ -0,0 +1,132 @@
1
+ /* Tomorrow Theme */
2
+ /* Original theme - https://github.com/chriskempson/tomorrow-theme */
3
+ /* Pretty printing styles. Used with prettify.js. */
4
+ /* SPAN elements with the classes below are added by prettyprint. */
5
+ /* plain text */
6
+ .pln {
7
+ color: #4d4d4c; }
8
+
9
+ @media screen {
10
+ /* string content */
11
+ .str {
12
+ color: #718c00; }
13
+
14
+ /* a keyword */
15
+ .kwd {
16
+ color: #8959a8; }
17
+
18
+ /* a comment */
19
+ .com {
20
+ color: #8e908c; }
21
+
22
+ /* a type name */
23
+ .typ {
24
+ color: #4271ae; }
25
+
26
+ /* a literal value */
27
+ .lit {
28
+ color: #f5871f; }
29
+
30
+ /* punctuation */
31
+ .pun {
32
+ color: #4d4d4c; }
33
+
34
+ /* lisp open bracket */
35
+ .opn {
36
+ color: #4d4d4c; }
37
+
38
+ /* lisp close bracket */
39
+ .clo {
40
+ color: #4d4d4c; }
41
+
42
+ /* a markup tag name */
43
+ .tag {
44
+ color: #c82829; }
45
+
46
+ /* a markup attribute name */
47
+ .atn {
48
+ color: #f5871f; }
49
+
50
+ /* a markup attribute value */
51
+ .atv {
52
+ color: #3e999f; }
53
+
54
+ /* a declaration */
55
+ .dec {
56
+ color: #f5871f; }
57
+
58
+ /* a variable name */
59
+ .var {
60
+ color: #c82829; }
61
+
62
+ /* a function name */
63
+ .fun {
64
+ color: #4271ae; } }
65
+ /* Use higher contrast and text-weight for printable form. */
66
+ @media print, projection {
67
+ .str {
68
+ color: #060; }
69
+
70
+ .kwd {
71
+ color: #006;
72
+ font-weight: bold; }
73
+
74
+ .com {
75
+ color: #600;
76
+ font-style: italic; }
77
+
78
+ .typ {
79
+ color: #404;
80
+ font-weight: bold; }
81
+
82
+ .lit {
83
+ color: #044; }
84
+
85
+ .pun, .opn, .clo {
86
+ color: #440; }
87
+
88
+ .tag {
89
+ color: #006;
90
+ font-weight: bold; }
91
+
92
+ .atn {
93
+ color: #404; }
94
+
95
+ .atv {
96
+ color: #060; } }
97
+ /* Style */
98
+ /*
99
+ pre.prettyprint {
100
+ background: white;
101
+ font-family: Consolas, Monaco, 'Andale Mono', monospace;
102
+ font-size: 12px;
103
+ line-height: 1.5;
104
+ border: 1px solid #ccc;
105
+ padding: 10px; }
106
+ */
107
+
108
+ /* Specify class=linenums on a pre to get line numbering */
109
+ ol.linenums {
110
+ margin-top: 0;
111
+ margin-bottom: 0; }
112
+
113
+ /* IE indents via margin-left */
114
+ li.L0,
115
+ li.L1,
116
+ li.L2,
117
+ li.L3,
118
+ li.L4,
119
+ li.L5,
120
+ li.L6,
121
+ li.L7,
122
+ li.L8,
123
+ li.L9 {
124
+ /* */ }
125
+
126
+ /* Alternate shading for lines */
127
+ li.L1,
128
+ li.L3,
129
+ li.L5,
130
+ li.L7,
131
+ li.L9 {
132
+ /* */ }
@@ -0,0 +1,44 @@
1
+ /* reset css */
2
+ html, body, div, span, applet, object, iframe,
3
+ h1, h2, h3, h4, h5, h6, p, blockquote, pre,
4
+ a, abbr, acronym, address, big, cite, code,
5
+ del, dfn, em, img, ins, kbd, q, s, samp,
6
+ small, strike, strong, sub, sup, tt, var,
7
+ b, u, i, center,
8
+ dl, dt, dd, ol, ul, li,
9
+ fieldset, form, label, legend,
10
+ table, caption, tbody, tfoot, thead, tr, th, td,
11
+ article, aside, canvas, details, embed,
12
+ figure, figcaption, footer, header, hgroup,
13
+ menu, nav, output, ruby, section, summary,
14
+ time, mark, audio, video {
15
+ margin: 0;
16
+ padding: 0;
17
+ border: 0;
18
+ font-size: 100%;
19
+ font: inherit;
20
+ vertical-align: baseline;
21
+ }
22
+ /* HTML5 display-role reset for older browsers */
23
+ article, aside, details, figcaption, figure,
24
+ footer, header, hgroup, menu, nav, section {
25
+ display: block;
26
+ }
27
+ body {
28
+ line-height: 1;
29
+ }
30
+ ol, ul {
31
+ list-style: none;
32
+ }
33
+ blockquote, q {
34
+ quotes: none;
35
+ }
36
+ blockquote:before, blockquote:after,
37
+ q:before, q:after {
38
+ content: '';
39
+ content: none;
40
+ }
41
+ table {
42
+ border-collapse: collapse;
43
+ border-spacing: 0;
44
+ }
package/import-map.json CHANGED
@@ -1,20 +1,20 @@
1
1
  {
2
2
  "imports": {
3
3
  "@eslint-community/eslint-plugin-eslint-comments": "npm:@eslint-community/eslint-plugin-eslint-comments@^4.3.0",
4
- "@stylistic/eslint-plugin": "npm:@stylistic/eslint-plugin@^2.1.0",
5
- "eslint-plugin-import-x": "npm:eslint-plugin-import-x@^0.5.1",
6
- "eslint-plugin-jsdoc": "npm:eslint-plugin-jsdoc@^48.2.9",
4
+ "@stylistic/eslint-plugin": "npm:@stylistic/eslint-plugin@^2.3.0",
5
+ "eslint-plugin-import-x": "npm:eslint-plugin-import-x@^3.0.1",
6
+ "eslint-plugin-jsdoc": "npm:eslint-plugin-jsdoc@^48.7.0",
7
7
  "eslint-plugin-no-secrets": "npm:eslint-plugin-no-secrets@^1.0.2",
8
8
  "eslint-plugin-perfectionist": "npm:eslint-plugin-perfectionist@^2.11.0",
9
- "eslint-plugin-promise": "npm:eslint-plugin-promise@^6.2.0",
9
+ "eslint-plugin-promise": "npm:eslint-plugin-promise@^6.4.0",
10
10
  "eslint-plugin-react": "./patches/eslint-plugin-react/index.js",
11
11
  "eslint-plugin-redos": "npm:eslint-plugin-redos@^4.4.5",
12
12
  "eslint-plugin-regexp": "npm:eslint-plugin-regexp@^2.6.0",
13
- "eslint-plugin-security": "npm:eslint-plugin-security@^3.0.0",
13
+ "eslint-plugin-security": "npm:eslint-plugin-security@^3.0.1",
14
14
  "eslint-plugin-sonarjs": "npm:eslint-plugin-sonarjs@^1.0.3",
15
- "eslint-plugin-tailwindcss": "npm:eslint-plugin-tailwindcss@^3.17.3",
16
- "eslint-plugin-unicorn": "npm:eslint-plugin-unicorn@^53.0.0",
17
- "globals": "npm:globals@^15.4.0",
15
+ "eslint-plugin-tailwindcss": "npm:eslint-plugin-tailwindcss@^3.17.4",
16
+ "eslint-plugin-unicorn": "npm:eslint-plugin-unicorn@^54.0.0",
17
+ "globals": "npm:globals@^15.8.0",
18
18
  "preact": "https://esm.sh/*preact@10.19.3?dev",
19
19
  "preact/jsx-runtime": "https://esm.sh/*preact@10.19.3/jsx-runtime?dev",
20
20
  "radash": "npm:radash"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pumpn/eslint-config",
3
- "version": "13.0.2",
3
+ "version": "13.2.0",
4
4
  "description": "standard eslint config for pumpn code projects",
5
5
  "main": "config.js",
6
6
  "author": "Nano Miratus <nanomiratus@gmail.com>",
@@ -12,31 +12,31 @@
12
12
  "url": "git+https://github.com/pumpncode/eslint-config.git"
13
13
  },
14
14
  "scripts": {
15
- "lint": "eslint .",
15
+ "lint": "eslint",
16
16
  "prepublishOnly": "npm run lint",
17
17
  "test": "echo 'no tests yet'"
18
18
  },
19
19
  "devDependencies": {
20
- "eslint": "^9.4.0",
20
+ "eslint": "^9.7.0",
21
21
  "funbridge-jsdoc-template": "github:52-entertainment/funbridge-react-jsdoc",
22
22
  "jsdoc-mermaid": "1.0.0"
23
23
  },
24
24
  "dependencies": {
25
25
  "@eslint-community/eslint-plugin-eslint-comments": "^4.3.0",
26
- "@stylistic/eslint-plugin": "^2.1.0",
27
- "eslint-plugin-import-x": "^0.5.1",
28
- "eslint-plugin-jsdoc": "^48.2.9",
26
+ "@stylistic/eslint-plugin": "^2.3.0",
27
+ "eslint-plugin-import-x": "^3.0.1",
28
+ "eslint-plugin-jsdoc": "^48.7.0",
29
29
  "eslint-plugin-no-secrets": "^1.0.2",
30
30
  "eslint-plugin-perfectionist": "^2.11.0",
31
- "eslint-plugin-promise": "^6.2.0",
31
+ "eslint-plugin-promise": "^6.4.0",
32
32
  "eslint-plugin-react": "github:jsx-eslint/eslint-plugin-react#pull/3759",
33
33
  "eslint-plugin-redos": "^4.4.5",
34
34
  "eslint-plugin-regexp": "^2.6.0",
35
- "eslint-plugin-security": "^3.0.0",
35
+ "eslint-plugin-security": "^3.0.1",
36
36
  "eslint-plugin-sonarjs": "^1.0.3",
37
- "eslint-plugin-tailwindcss": "^3.17.3",
38
- "eslint-plugin-unicorn": "^53.0.0",
39
- "globals": "^15.4.0"
37
+ "eslint-plugin-tailwindcss": "^3.17.4",
38
+ "eslint-plugin-unicorn": "^54.0.0",
39
+ "globals": "^15.8.0"
40
40
  },
41
41
  "peerDependencies": {
42
42
  "eslint": "^9.4.0"
@@ -57,7 +57,7 @@ const staticAnalysisRules = {
57
57
  }
58
58
  ],
59
59
  "import-x/no-self-import": "error",
60
- // TODO [2024-07-01]: Change to "error" when there is a resolver for deno
60
+ // TODO [2024-08-01]: Change to "error" when there is a resolver for deno
61
61
  "import-x/no-unresolved": "off",
62
62
  "import-x/no-useless-path-segments": [
63
63
  "error",
package/rules/jsdoc.js CHANGED
@@ -16,6 +16,24 @@ const jsdocRules = {
16
16
  ],
17
17
  "jsdoc/check-types": "warn",
18
18
  "jsdoc/check-values": "warn",
19
+ "jsdoc/convert-to-jsdoc-comments": [
20
+ "warn",
21
+ {
22
+ allowedPrefixes: [
23
+ "@ts-",
24
+ "istanbul ",
25
+ "c8 ",
26
+ "v8 ",
27
+ "eslint",
28
+ "prettier-",
29
+ "TODO",
30
+ "MARK"
31
+ ],
32
+ enableFixer: true,
33
+ enforceJsdocLineStyle: "multi",
34
+ lineOrBlockStyle: "both"
35
+ }
36
+ ],
19
37
  "jsdoc/empty-tags": "warn",
20
38
  "jsdoc/implements-on-classes": "warn",
21
39
  "jsdoc/imports-as-dependencies": "off",
@@ -74,7 +92,7 @@ const jsdocRules = {
74
92
  // "ImportExpression",
75
93
  // "LogicalExpression",
76
94
  // "LogicalExpression",
77
- "MemberExpression",
95
+ // "MemberExpression",
78
96
  "MethodDefinition"
79
97
  // "ModuleDeclarations",
80
98
  // "ModuleExpression",
@@ -146,6 +164,12 @@ const jsdocRules = {
146
164
  "jsdoc/require-returns-check": "warn",
147
165
  "jsdoc/require-returns-description": "warn",
148
166
  "jsdoc/require-returns-type": "warn",
167
+ "jsdoc/require-template": [
168
+ "warn",
169
+ {
170
+ requireSeparateTemplates: true
171
+ }
172
+ ],
149
173
  "jsdoc/require-throws": "warn",
150
174
  "jsdoc/require-yields": "warn",
151
175
  "jsdoc/require-yields-check": "warn",
@@ -33,7 +33,7 @@ const bestPracticesRules = {
33
33
  "regexp/prefer-regexp-test": "off",
34
34
  "regexp/prefer-set-operation": "error",
35
35
  "regexp/require-unicode-regexp": "error",
36
- // TODO [2024-07-01]: enable when https://github.com/microsoft/vscode/pull/206580 is resolved
36
+ // TODO [2024-08-01]: enable when https://github.com/microsoft/vscode/pull/206580 is resolved
37
37
  "regexp/require-unicode-sets-regexp": "off",
38
38
  "regexp/simplify-set-operations": "error",
39
39
  "regexp/sort-alternatives": "error",
@@ -1,5 +1,5 @@
1
1
  const maximumCognitiveComplexity = 15;
2
- const maxSwitchCases = 5;
2
+ const maxSwitchCases = 20;
3
3
  const duplicateStringThreshold = 3;
4
4
  const identicalFunctionThreshold = 3;
5
5
 
@@ -69,7 +69,7 @@ const suggestionsRules = {
69
69
  }
70
70
  ],
71
71
  "id-match": "off",
72
- "init-declarations": "warn",
72
+ "init-declarations": "off",
73
73
  "logical-assignment-operators": "error",
74
74
  "multiline-comment-style": "off",
75
75
  "new-cap": "error",
package/rules/unicorn.js CHANGED
@@ -71,6 +71,7 @@ const unicornRules = {
71
71
  "unicorn/no-lonely-if": "error",
72
72
  "unicorn/no-magic-array-flat-depth": "error",
73
73
  "unicorn/no-negated-condition": "error",
74
+ "unicorn/no-negation-in-equality-check": "error",
74
75
  "unicorn/no-nested-ternary": "error",
75
76
  "unicorn/no-new-array": "error",
76
77
  "unicorn/no-new-buffer": "error",