Skip to content
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

docs: rule documentation harmonization #198

Merged
merged 4 commits into from Apr 30, 2024

Conversation

MikeMcC399
Copy link
Collaborator

Issues

This PR deals with issues in the set of 9 docs/rules Markdown files.

  1. The top-level headers of the docs/rules documents do not agree with the lib/rules property meta.docs.description.
  2. Some headers do not include the name of the rule.
  3. Formatting of the docs/rules documents is inconsistent.

Changes

  1. Top-level headers of the docs/rules documents are built using the meta.docs.description property from the corresponding lib/rules source.
  2. The docs/rules top-level header has the name of the rule in the form (cypress/<rule-name>) consistently appended.
  3. Lower level headings and content are aligned with the Yeoman-based ESLint generator eslint/generator-eslint template _doc.md as follows:
- Rule Details
  - Options
- When Not To Use It
- Further Reading
  1. Other grammatical text changes are made.
  2. The documents are prepared for auto-generated content

Comments

  • This PR only aims to restructure existing information.

  • There is scope for further improvement of rule documents by adding content. For instance, the docs/rules/no-unnecessary-waiting.md essentially contains only a link to the Cypress documentation site without providing any other description or summary. This could optionally be covered in a later PR.

  • Due to issues with the document generator incorrectly duplicating headers in some situations, the planned PR to add the npm module eslint-doc-generator is held back for the time being. The issues have been reported and PR OS-agnostic handling of end-of-line characters bmish/eslint-doc-generator#524 plans to address.

@cypress-app-bot
Copy link

@MikeMcC399
Copy link
Collaborator Author

@MikeMcC399 MikeMcC399 marked this pull request as ready for review April 29, 2024 07:37
Copy link
Member

@jennifer-shehane jennifer-shehane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for standardizing this. It's much better.

@jennifer-shehane jennifer-shehane merged commit 7fe8a49 into cypress-io:master Apr 30, 2024
6 checks passed
@MikeMcC399
Copy link
Collaborator Author

@jennifer-shehane

Thanks for standardizing this. It's much better.

It's taking shape bit by bit! Thanks for merging!

@MikeMcC399 MikeMcC399 deleted the rule-doc-harmonization branch May 1, 2024 05:43
@cypress-app-bot
Copy link

🎉 This PR is included in version 3.0.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

None yet

3 participants