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: add formatting.md #1359

Closed
wants to merge 27 commits into from
Closed
Changes from 7 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
0129733
Create formatting.md
starlightknown Feb 20, 2023
5e528a3
add: code blocks
starlightknown Feb 20, 2023
705b144
Update docs/community/styleguide/formatting.md
starlightknown Feb 20, 2023
0d6ec42
Update formatting.md
starlightknown Feb 20, 2023
e252a13
Merge branch 'master' into formatting
quetzalliwrites Feb 22, 2023
517dfc7
Merge branch 'master' into formatting
starlightknown Apr 25, 2023
6433bfd
Merge branch 'master' into formatting
starlightknown Jun 6, 2023
518a3ee
Merge branch 'master' into formatting
quetzalliwrites Jun 7, 2023
dfce213
Update docs/community/styleguide/formatting.md
starlightknown Jun 11, 2023
bd03ef2
Update docs/community/styleguide/formatting.md
starlightknown Jun 11, 2023
73c720d
Update docs/community/styleguide/formatting.md
starlightknown Jun 11, 2023
5c4f62a
Update formatting.md
starlightknown Jun 11, 2023
ba19e1e
Merge branch 'master' into formatting
starlightknown Jun 11, 2023
4f3aeb9
Update formatting.md
starlightknown Jun 11, 2023
95d4651
Merge branch 'master' into formatting
quetzalliwrites Jun 14, 2023
ad81a63
Merge branch 'master' into formatting
quetzalliwrites Jun 16, 2023
7401a66
grammar fixes
quetzalliwrites Jun 16, 2023
f65e34a
Merge branch 'master' into formatting
starlightknown Jul 11, 2023
dfa1ec7
Rename docs/community/styleguide/formatting.md to pages/docs/communit…
starlightknown Jul 11, 2023
ff80d1e
Update formatting.md
starlightknown Jul 11, 2023
77b7e71
Added _section.md for styleguide
akshatnema Jul 11, 2023
75d2447
Merge branch 'master' into formatting
starlightknown Jul 12, 2023
91d7f5c
Merge branch 'master' into formatting
starlightknown Aug 22, 2023
758580f
Merge branch 'master' into formatting
starlightknown Nov 27, 2023
0b89fe4
fix title
quetzalliwrites Nov 28, 2023
52d6653
Merge branch 'master' into formatting
quetzalliwrites Mar 7, 2024
8151476
Update formatting.md
starlightknown Mar 7, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 69 additions & 0 deletions docs/community/styleguide/formatting.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
---
quetzalliwrites marked this conversation as resolved.
Show resolved Hide resolved
title: Formatting style guide
starlightknown marked this conversation as resolved.
Show resolved Hide resolved
description: This style guide explains using correct formats when writing documentation.
starlightknown marked this conversation as resolved.
Show resolved Hide resolved
weight:
Copy link
Member

Choose a reason for hiding this comment

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

why is the number for the page weight missing? please assign one

---
## Documentation formatting

Copy link
Member

Choose a reason for hiding this comment

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

Please add a paragraph or sentence introducing the topic "Documentation formatting".

### Notes and warning blocks

Notes and warning blocks are used to draw attention to important information. Use the following markdown features when necessary:

- Use a clear and concise heading to introduce the note or warning.
- Use short paragraphs or bullet points to convey the information.
- Keep the language simple and direct.
- Use an `>` in markdown to indicate the nature of the note or warning.
- Use the following Use the following syntax to apply a style. Currently our documenation supports **Remember** `<Remember>`:
* Surround the text with an opening and closing tag.
* Use the following syntax to apply a style:
` <Remember>
No need to add a prefix (Remember); the tag automatically provides one
</Remember>`

The output:
<Remember>
No need to add a prefix (Remember); the tag automatically provides one
</Remember>
Copy link
Member

Choose a reason for hiding this comment

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

This entire section is confusing, and I can't understand it. 😄✌🏽 What are you documenting here? It is not clear that you're explaining that we have a React component for creating a remember card.

Also, why do you have the (remember) in the middle of that sentence in line 20? What do you mean by "no need to add a prefix"? What prefix are you talking about? 👀

Please rewrite this section and think about all the pieces you are trying to educate the reader on ✌🏽

Copy link
Contributor Author

Choose a reason for hiding this comment

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

even after adding tags some people might think they need to write "Remember" inside of tags to make it work. That's what I wanted to address


## Code Blocks
starlightknown marked this conversation as resolved.
Show resolved Hide resolved

Code blocks are used to display code examples or snippets.

- In a Markdown document, use the `<CodeBlock>` tag and specify the language.
* Use the following syntax to apply a codeblock:
`<CodeBlock language="bash">
{`npm start`}
</CodeBlock>`

The output:

<CodeBlock language="bash">
{`npm start`}
</CodeBlock>

- Use code style for filenames, directories, and paths. For example: Go to the `/docs/tutorials` directory.
- Use indentation to show the structure of the code.
- Use single backticks to enclose inline code. For example, `asyncapi new --example=tutorial.yml --no-tty`
- Remove trailing spaces in the code.
- For yaml document, enclose with triple backticks and specify `yaml`. (```)
* Use this syntax:
` ```yaml
asyncapi: '2.5.0'
info:
title: Account Service
version: 1.0.0
``` `

* The output:
```yaml
asyncapi: '2.5.0'
info:
title: Account Service
version: 1.0.0
```
## Spacing

Line spacing, or the amount of vertical space between lines of text in a paragraph, can aid or hinder reading. Adequate line spacing aids readers in navigating from the end of one line to the start of the next.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Line spacing, or the amount of vertical space between lines of text in a paragraph, can aid or hinder reading. Adequate line spacing aids readers in navigating from the end of one line to the start of the next.
Line spacing, which refers to the vertical space between lines of text in a paragraph, can either facilitate or hinder reading.


- Use appropriate line spacing to make the content more readable. A single line spacing is usually sufficient for most cases.
- Use consistent indentation to show the hierarchy of the content.