This style guide outlines the formatting rules for markdown files in this repository. These rules are enforced by markdownlint and are optimized for GitBook compatibility.
- Use a markdownlint extension for your editor of choice.
- Use a typos extension for your editor of choice.
- Run a markdownlint check before pushing code.
- Run a typos check before pushing code.
Alternatively (and this is recommended at least as additional step) you could ask an integrated LLM to do a check for spelling, grammar and markdown compliance (based on the .markdownlint.json file).
- Use 2 spaces for indentation
- No hard tabs allowed
- No trailing spaces at the end of lines
- Use dashes (
-) for unordered lists - Maximum line length is not enforced (MD013 is disabled)
- First line of the file does not need to be a top-level heading (MD041 is disabled)
- Multiple headings with the same content are allowed (MD024 is disabled)
- Multiple top-level headings are allowed (MD025 is disabled)
GitBook prefers inline links over reference-style links. However, to manage links and facilitate updating in this repository we urge you to use reference style links.
Note that there is a Github workflow in the Gitbook synced repository to transform reference style links for content that is synced from source repositories (like
nexus-sdkandnexus-next). This ensures that all links in thegitbook-docsrepo are inline style links for Gitbook compatibility.
In this repo, use reference-style links at the bottom of the file:
...
[Link text][reference]
...
<!-- List of references -->
[reference]: https://example.comover inline links, like:
[Link text](https://example.com)- Use consistent numbering style (MD029)
- Use dashes (
-) for unordered lists (MD004) - Indent list items with 2 spaces (MD007)
- Avoid using the following punctuation at the end of headings:
.,,,;,:,!(MD026)
- HTML tags are allowed (MD033 is disabled)
- Use proper escaping for special characters
- Keep content clear and concise
- Use descriptive link text
- Maintain consistent formatting throughout the document
- Use proper heading hierarchy
- Include alt text for images
- Use code blocks with appropriate language specification
Remember to run the markdown linter to ensure your content follows these guidelines.