Markdown Style Guide
The Rocket.Chat documentation utilizes the Markdown Markup Language (a "Cheatsheet" is available here). Markdown can be composed in a variety of styles, but this document outlines the standard formatting guide for creating Rocket.Chat documentation. Please note, we are presently implementing a markdown linter on incoming Pull Requests. Therefore, it's advisable to ensure your commits pass the linting test prior to submitting a Pull Request. Each rule listed here includes its respective code, so if the linter flags an issue, you can refer back to this guide to identify the broken rule.
This markdown guide is intended solely for contributing to documentation. To view the supported markdown formats in a Rocket.Chat workspace, please refer to the Messages user guide.
Rules | Description | Wrong | Correct |
---|---|---|---|
MD001 - Header levels should only increment by one level at a time | Headers should not be skipped, but instead incremented one by one. | ||
MD002 - First header should be a top-level header | The first header of the document should be a top-level header (H1). | ||
MD003 - Header style | The header style used on documents should be | ||
MD004 - Unordered list style | Lists should be created using asterisks. | ||
MD005 - No inconsistent indentation for list items at the same level | Lists should maintain consistent indentation. Typically, any violation of this rule is due to a typographical error. | ||
MD006 - Start bulleted lists at the beginning of the line | Lists with bullet points should commence at the start of the line | ||
MD007 - Unordered list indentation | List items should be indented using 4 spaces. | ||
MD009 - No trailing spaces | There should be no trailing spaces at the end of lines. To rectify this, locate the flagged line and eliminate any spaces trailing at its end. | ||
MD010 - No hard tabs | Indentation should be achieved using spaces, not hard tabs. | ||
MD011 - No reversed link syntax | When creating links you should use the | ||
MD012 - No multiple consecutive blank lines | The document should not contain more than one consecutive blank line. | ||
MD018 - Use space after hash on atx style header | There should be a space after the hashes on atx style headers. | ||
MD019 - No multiple spaces after hash on atx style header | In atx style headers, there should not be more than one space following the hash symbol. | ||
MD022 - Headers should be surrounded by blank lines | Every header should be preceded and followed by a blank line, unless the header is positioned at the start or end of the document. | ||
MD023 - Headers must start at the beginning of the line | |||
MD025 - No multiple top-level headers in the same document | A document should contain only one top-level header (h1) | ||
MD027 - No multiple spaces after the blockquote symbol | Blockquote should not have more than one space after the blockquote symbol ( | ||
MD028 - No blank line inside blockquote | A blockquote should not contain a blank line within it. However, if the lines are intended to be part of the same quote, then prepend the blockquote symbol to the start of the blank line. | ||
MD029 - Ordered list item prefix | Ordered lists should be ordered by a prefix that increases in numerical order. | ||
MD030 - Space after list markers | There should be only one space after a list marker. | ||
MD031 - Fenced code blocks should be surrounded by blank lines | |||
MD032 - Lists should be surrounded by blank lines | |||
MD034 - No bare URLs | Bare URLs should not be present in the document; instead, enclose the links within angle brackets (< >). | ||
MD035 - Horizontal rule style | Horizontal rules should be created using three slashes ( | ||
MD037 - No spaces inside emphasis markers | Spaces should not be present within emphasis markers (such as bold or italic). | ||
MD038 - No spaces inside code span elements | Spaces should not be included within code span elements. | ||
MD039 - No spaces inside the link text | |||
MD046 - Code block style | Code blocks should be fenced. |
For a comprehensive guide on contributing to Rocket.Chat documentation, visit Documentation Contribution Guidelinesand Documentation Template
Last updated