Skip to content

Commit 983e0fe

Browse files
authored
docs: split rules list into rule/test-related rules (#341)
1 parent 3ffd85e commit 983e0fe

File tree

3 files changed

+15
-7
lines changed

3 files changed

+15
-7
lines changed

Diff for: .eslint-doc-generatorrc.js

+1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,6 @@
22
module.exports = {
33
ignoreConfig: ['all', 'rules', 'rules-recommended', 'tests', 'tests-recommended'],
44
ruleDocSectionInclude: ['Rule Details'],
5+
ruleListSplit: 'meta.docs.category',
56
urlConfigs: 'https://github.com/eslint-community/eslint-plugin-eslint-plugin#presets',
67
};

Diff for: README.md

+13-6
Original file line numberDiff line numberDiff line change
@@ -61,23 +61,21 @@ Here's an example ESLint configuration that:
6161
🔧 Automatically fixable by the [`--fix` CLI option](https://eslint.org/docs/user-guide/command-line-interface#--fix).\
6262
💡 Manually fixable by [editor suggestions](https://eslint.org/docs/developer-guide/working-with-rules#providing-suggestions).
6363

64+
### Rules
65+
6466
| Name                          | Description | 💼 | 🔧 | 💡 |
6567
| :--------------------------------------------------------------------------- | :----------------------------------------------------------------------------------------- | :- | :- | :- |
66-
| [consistent-output](docs/rules/consistent-output.md) | enforce consistent use of `output` assertions in rule tests || | |
6768
| [fixer-return](docs/rules/fixer-return.md) | require fixer functions to return a fix || | |
6869
| [meta-property-ordering](docs/rules/meta-property-ordering.md) | enforce the order of meta properties | | 🔧 | |
6970
| [no-deprecated-context-methods](docs/rules/no-deprecated-context-methods.md) | disallow usage of deprecated methods on rule context objects || 🔧 | |
7071
| [no-deprecated-report-api](docs/rules/no-deprecated-report-api.md) | disallow the version of `context.report()` with multiple arguments || 🔧 | |
71-
| [no-identical-tests](docs/rules/no-identical-tests.md) | disallow identical tests || 🔧 | |
7272
| [no-missing-message-ids](docs/rules/no-missing-message-ids.md) | disallow `messageId`s that are missing from `meta.messages` || | |
7373
| [no-missing-placeholders](docs/rules/no-missing-placeholders.md) | disallow missing placeholders in rule report messages || | |
74-
| [no-only-tests](docs/rules/no-only-tests.md) | disallow the test case property `only` || | 💡 |
7574
| [no-unused-message-ids](docs/rules/no-unused-message-ids.md) | disallow unused `messageId`s in `meta.messages` || | |
7675
| [no-unused-placeholders](docs/rules/no-unused-placeholders.md) | disallow unused placeholders in rule report messages || | |
7776
| [no-useless-token-range](docs/rules/no-useless-token-range.md) | disallow unnecessary calls to `sourceCode.getFirstToken()` and `sourceCode.getLastToken()` || 🔧 | |
7877
| [prefer-message-ids](docs/rules/prefer-message-ids.md) | require using `messageId` instead of `message` to report rule violations || | |
7978
| [prefer-object-rule](docs/rules/prefer-object-rule.md) | disallow function-style rules || 🔧 | |
80-
| [prefer-output-null](docs/rules/prefer-output-null.md) | disallow invalid RuleTester test cases where the `output` matches the `code` || 🔧 | |
8179
| [prefer-placeholders](docs/rules/prefer-placeholders.md) | require using placeholders for dynamic report messages | | | |
8280
| [prefer-replace-text](docs/rules/prefer-replace-text.md) | require using `replaceText()` instead of `replaceTextRange()` | | | |
8381
| [report-message-format](docs/rules/report-message-format.md) | enforce a consistent format for rule report messages | | | |
@@ -87,8 +85,17 @@ Here's an example ESLint configuration that:
8785
| [require-meta-has-suggestions](docs/rules/require-meta-has-suggestions.md) | require suggestable rules to implement a `meta.hasSuggestions` property || 🔧 | |
8886
| [require-meta-schema](docs/rules/require-meta-schema.md) | require rules to implement a `meta.schema` property || | 💡 |
8987
| [require-meta-type](docs/rules/require-meta-type.md) | require rules to implement a `meta.type` property || | |
90-
| [test-case-property-ordering](docs/rules/test-case-property-ordering.md) | require the properties of a test case to be placed in a consistent order | | 🔧 | |
91-
| [test-case-shorthand-strings](docs/rules/test-case-shorthand-strings.md) | enforce consistent usage of shorthand strings for test cases with no options | | 🔧 | |
88+
89+
### Tests
90+
91+
| Name                        | Description | 💼 | 🔧 | 💡 |
92+
| :----------------------------------------------------------------------- | :--------------------------------------------------------------------------- | :- | :- | :- |
93+
| [consistent-output](docs/rules/consistent-output.md) | enforce consistent use of `output` assertions in rule tests || | |
94+
| [no-identical-tests](docs/rules/no-identical-tests.md) | disallow identical tests || 🔧 | |
95+
| [no-only-tests](docs/rules/no-only-tests.md) | disallow the test case property `only` || | 💡 |
96+
| [prefer-output-null](docs/rules/prefer-output-null.md) | disallow invalid RuleTester test cases where the `output` matches the `code` || 🔧 | |
97+
| [test-case-property-ordering](docs/rules/test-case-property-ordering.md) | require the properties of a test case to be placed in a consistent order | | 🔧 | |
98+
| [test-case-shorthand-strings](docs/rules/test-case-shorthand-strings.md) | enforce consistent usage of shorthand strings for test cases with no options | | 🔧 | |
9299

93100
<!-- end auto-generated rules list -->
94101

Diff for: package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
"eslint": "^8.23.0",
5858
"eslint-config-not-an-aardvark": "^2.1.0",
5959
"eslint-config-prettier": "^8.5.0",
60-
"eslint-doc-generator": "^1.0.0",
60+
"eslint-doc-generator": "^1.4.3",
6161
"eslint-plugin-eslint-comments": "^3.2.0",
6262
"eslint-plugin-eslint-plugin": "file:./",
6363
"eslint-plugin-markdown": "^3.0.0",

0 commit comments

Comments
 (0)