Skip to content

Ensure rule docs mention all rule options #226

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 31, 2021

Conversation

bmish
Copy link
Member

@bmish bmish commented Oct 30, 2021

Add test to ensure:

  1. Any rule with options has a ## Options section in its rule doc.
  2. Any named rule options (for example, the pattern option for the require-meta-docs-description rule) are mentioned in the rule doc.

Based on the same test I wrote here: https://github.com/ember-cli/eslint-plugin-ember/blob/4f26c0bc7e34400007e02939a9c6e183078a3e87/tests/rule-setup.js#L111

Eventually, I'd like to add a lint rule to enforce these "rule setup" tests for any eslint plugin.

@bmish bmish force-pushed the rule-setup-test-options branch from 9a20367 to bb5cda0 Compare October 30, 2021 20:07
@aladdin-add
Copy link
Contributor

Eventually, I'd like to add a lint rule to enforce these "rule setup" tests for any eslint plugin.

eslint does not support ext in config files, so users have to use eslint --ext=.js,.md?

@aladdin-add aladdin-add merged commit 138bb90 into eslint-community:master Oct 31, 2021
@bmish
Copy link
Member Author

bmish commented Oct 31, 2021

Eventually, I'd like to add a lint rule to enforce these "rule setup" tests for any eslint plugin.

eslint does not support ext in config files, so users have to use eslint --ext=.js,.md?

More likely, the rule would be similar to #2, where a violation is reported in the rule JS file if the documentation file that we manually read in is missing or has missing sections.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants