@radham/eslint-config 8.0.0 → 9.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/CHANGELOG.md +30 -3
- package/README.md +5 -1
- package/package.json +18 -9
- package/src/gfm.js +22 -0
- package/src/index.js +28 -1
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,28 @@ All notable changes to this project will be documented in this file.
|
|
|
6
6
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
7
7
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
8
8
|
|
|
9
|
+
[9.0.0] - 2025-11-06
|
|
10
|
+
--------------------
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- The `eslint-plugin-unicorn` package with the `unopinionated` ruleset and some additional custom
|
|
15
|
+
configuration.
|
|
16
|
+
|
|
17
|
+
### Changed
|
|
18
|
+
|
|
19
|
+
- Upgraded the `@eslint/compat` dependency from `1.4.0` to `1.4.1`.
|
|
20
|
+
- Upgraded the `@eslint/js` dependency from `9.38.0` to `9.39.1`.
|
|
21
|
+
- Upgraded the `@eslint/markdown` dependency from `7.5.0` to `7.5.1`.
|
|
22
|
+
- Upgraded the `typescript-eslint` dependency from `8.46.2` to `8.46.3`.
|
|
23
|
+
|
|
24
|
+
[8.1.0] - 2025-10-24
|
|
25
|
+
--------------------
|
|
26
|
+
|
|
27
|
+
### Added
|
|
28
|
+
|
|
29
|
+
- A `radhamGfm` config for [GitHub Flavored Markdown](https://github.github.com/gfm/) documents.
|
|
30
|
+
|
|
9
31
|
[8.0.0] - 2025-10-20
|
|
10
32
|
--------------------
|
|
11
33
|
|
|
@@ -39,7 +61,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
39
61
|
|
|
40
62
|
### Added
|
|
41
63
|
|
|
42
|
-
- The [no-only-tests](https://github.com/levibuzolic/eslint-plugin-no-only-tests) plugin and
|
|
64
|
+
- The [no-only-tests](https://github.com/levibuzolic/eslint-plugin-no-only-tests) plugin and
|
|
65
|
+
corresponding rule.
|
|
43
66
|
|
|
44
67
|
### Changed
|
|
45
68
|
|
|
@@ -71,11 +94,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
71
94
|
|
|
72
95
|
### Added
|
|
73
96
|
|
|
74
|
-
- Set the `@typescript-eslint/no-unused-vars` options `argsIgnorePattern` and
|
|
97
|
+
- Set the `@typescript-eslint/no-unused-vars` options `argsIgnorePattern` and
|
|
98
|
+
`destructuredArrayIgnorePattern` to `'^_'`.
|
|
75
99
|
|
|
76
100
|
### Changed
|
|
77
101
|
|
|
78
|
-
- Update the `@typescript-eslint/no-unused-vars` option `caughtErrorsIgnorePattern` to `'^_'` from
|
|
102
|
+
- Update the `@typescript-eslint/no-unused-vars` option `caughtErrorsIgnorePattern` to `'^_'` from
|
|
103
|
+
`'^_$'`.
|
|
79
104
|
|
|
80
105
|
[1.0.1] - 2025-08-25
|
|
81
106
|
--------------------
|
|
@@ -95,6 +120,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
95
120
|
|
|
96
121
|
- Initial release.
|
|
97
122
|
|
|
123
|
+
[9.0.0]: https://github.com/jbenner-radham/eslint-config/compare/v8.1.0...v9.0.0
|
|
124
|
+
[8.1.0]: https://github.com/jbenner-radham/eslint-config/compare/v8.0.0...v8.1.0
|
|
98
125
|
[8.0.0]: https://github.com/jbenner-radham/eslint-config/compare/v7.0.0...v8.0.0
|
|
99
126
|
[7.0.0]: https://github.com/jbenner-radham/eslint-config/compare/v6.0.0...v7.0.0
|
|
100
127
|
[6.0.0]: https://github.com/jbenner-radham/eslint-config/compare/v5.0.0...v6.0.0
|
package/README.md
CHANGED
|
@@ -15,7 +15,7 @@ Usage
|
|
|
15
15
|
|
|
16
16
|
```javascript
|
|
17
17
|
import { includeIgnoreFile } from '@eslint/compat';
|
|
18
|
-
import radham from '@radham/eslint-config';
|
|
18
|
+
import radham, { radhamGfm } from '@radham/eslint-config';
|
|
19
19
|
import { defineConfig } from 'eslint/config';
|
|
20
20
|
import globals from 'globals';
|
|
21
21
|
import path from 'node:path';
|
|
@@ -31,6 +31,10 @@ export default defineConfig([
|
|
|
31
31
|
files: ['**/*.ts'],
|
|
32
32
|
extends: [radham],
|
|
33
33
|
languageOptions: { globals: globals.node /* or `globals.browser` */ }
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
files: ['**/*.md'],
|
|
37
|
+
extends: [radhamGfm]
|
|
34
38
|
}
|
|
35
39
|
]);
|
|
36
40
|
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@radham/eslint-config",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "9.0.0",
|
|
4
4
|
"description": "A shareable ESLint config with Stylistic.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -9,6 +9,14 @@
|
|
|
9
9
|
"stylistic",
|
|
10
10
|
"typescript"
|
|
11
11
|
],
|
|
12
|
+
"homepage": "https://github.com/jbenner-radham/eslint-config#readme",
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://github.com/jbenner-radham/eslint-config/issues"
|
|
15
|
+
},
|
|
16
|
+
"repository": {
|
|
17
|
+
"type": "git",
|
|
18
|
+
"url": "git+https://github.com/jbenner-radham/eslint-config.git"
|
|
19
|
+
},
|
|
12
20
|
"license": "BSD-3-Clause",
|
|
13
21
|
"author": "James Benner <hello@jamesbenner.com> (https://www.jamesbenner.com/)",
|
|
14
22
|
"type": "module",
|
|
@@ -18,20 +26,21 @@
|
|
|
18
26
|
"CHANGELOG.md"
|
|
19
27
|
],
|
|
20
28
|
"dependencies": {
|
|
21
|
-
"@eslint/compat": "^1.4.
|
|
22
|
-
"@eslint/js": "^9.
|
|
29
|
+
"@eslint/compat": "^1.4.1",
|
|
30
|
+
"@eslint/js": "^9.39.1",
|
|
31
|
+
"@eslint/markdown": "^7.5.1",
|
|
23
32
|
"@stylistic/eslint-plugin": "^5.5.0",
|
|
24
33
|
"eslint-plugin-no-only-tests": "^3.3.0",
|
|
25
34
|
"eslint-plugin-sort": "^4.0.0",
|
|
26
|
-
"
|
|
35
|
+
"eslint-plugin-unicorn": "^62.0.0",
|
|
36
|
+
"typescript-eslint": "^8.46.3"
|
|
27
37
|
},
|
|
28
38
|
"devDependencies": {
|
|
29
|
-
"@eslint/json": "^0.
|
|
30
|
-
"
|
|
31
|
-
"
|
|
32
|
-
"globals": "^16.4.0",
|
|
39
|
+
"@eslint/json": "^0.14.0",
|
|
40
|
+
"eslint": "^9.39.1",
|
|
41
|
+
"globals": "^16.5.0",
|
|
33
42
|
"husky": "^9.1.7",
|
|
34
|
-
"lint-staged": "^16.2.
|
|
43
|
+
"lint-staged": "^16.2.6",
|
|
35
44
|
"np": "^10.2.0",
|
|
36
45
|
"sort-package-json": "^3.4.0"
|
|
37
46
|
},
|
package/src/gfm.js
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import markdown from '@eslint/markdown';
|
|
2
|
+
import { defineConfig } from 'eslint/config';
|
|
3
|
+
|
|
4
|
+
export default defineConfig([
|
|
5
|
+
{
|
|
6
|
+
plugins: { markdown },
|
|
7
|
+
language: 'markdown/gfm',
|
|
8
|
+
extends: ['markdown/recommended'],
|
|
9
|
+
rules: {
|
|
10
|
+
// Allow GFM Alerts. See: https://tinyurl.com/gfm-alerts
|
|
11
|
+
'markdown/no-missing-label-refs': ['error', {
|
|
12
|
+
allowLabels: [
|
|
13
|
+
'!CAUTION',
|
|
14
|
+
'!IMPORTANT',
|
|
15
|
+
'!NOTE',
|
|
16
|
+
'!TIP',
|
|
17
|
+
'!WARNING'
|
|
18
|
+
]
|
|
19
|
+
}]
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
]);
|
package/src/index.js
CHANGED
|
@@ -4,13 +4,19 @@ import stylistic from '@stylistic/eslint-plugin';
|
|
|
4
4
|
import { defineConfig } from 'eslint/config';
|
|
5
5
|
import noOnlyTests from 'eslint-plugin-no-only-tests';
|
|
6
6
|
import sort from 'eslint-plugin-sort';
|
|
7
|
+
import unicorn from 'eslint-plugin-unicorn';
|
|
7
8
|
import tseslint from 'typescript-eslint';
|
|
8
9
|
|
|
9
10
|
export default defineConfig([
|
|
10
11
|
sort.configs['flat/recommended'],
|
|
11
12
|
tseslint.configs.recommended,
|
|
13
|
+
unicorn.configs.unopinionated,
|
|
12
14
|
{
|
|
13
|
-
plugins: {
|
|
15
|
+
plugins: {
|
|
16
|
+
'@stylistic': stylistic,
|
|
17
|
+
'no-only-tests': fixupPluginRules(noOnlyTests),
|
|
18
|
+
js
|
|
19
|
+
},
|
|
14
20
|
extends: ['js/recommended'],
|
|
15
21
|
rules: {
|
|
16
22
|
'@stylistic/arrow-parens': ['error', 'as-needed'],
|
|
@@ -108,8 +114,27 @@ export default defineConfig([
|
|
|
108
114
|
],
|
|
109
115
|
'sort/import-members': ['error', { caseSensitive: false, natural: true }],
|
|
110
116
|
'sort/object-properties': 'off',
|
|
117
|
+
'unicorn/better-regex': ['error', { sortCharacterClasses: true }],
|
|
118
|
+
'unicorn/catch-error-name': 'error',
|
|
119
|
+
'unicorn/consistent-destructuring': 'error',
|
|
120
|
+
'unicorn/consistent-empty-array-spread': 'error',
|
|
121
|
+
'unicorn/custom-error-definition': 'error',
|
|
122
|
+
'unicorn/empty-brace-spaces': 'error',
|
|
123
|
+
'unicorn/expiring-todo-comments': 'off',
|
|
124
|
+
'unicorn/filename-case': ['error', {
|
|
125
|
+
cases: { kebabCase: true, pascalCase: true }
|
|
126
|
+
}],
|
|
127
|
+
'unicorn/no-await-expression-member': 'error',
|
|
128
|
+
'unicorn/no-for-loop': 'error',
|
|
129
|
+
'unicorn/no-nested-ternary': 'error',
|
|
130
|
+
'unicorn/no-static-only-class': 'off',
|
|
131
|
+
'unicorn/no-useless-length-check': 'off',
|
|
132
|
+
'unicorn/prefer-set-has': 'off',
|
|
133
|
+
'unicorn/prefer-set-size': 'off',
|
|
134
|
+
'unicorn/prevent-abbreviations': 'error',
|
|
111
135
|
camelcase: 'error',
|
|
112
136
|
eqeqeq: ['error', 'smart'],
|
|
137
|
+
'no-nested-ternary': 'off',
|
|
113
138
|
'no-unused-vars': 'off',
|
|
114
139
|
'no-var': 'error',
|
|
115
140
|
'prefer-const': ['error', { destructuring: 'any', ignoreReadBeforeAssign: false }],
|
|
@@ -117,3 +142,5 @@ export default defineConfig([
|
|
|
117
142
|
}
|
|
118
143
|
}
|
|
119
144
|
]);
|
|
145
|
+
|
|
146
|
+
export { default as radhamGfm } from './gfm.js';
|