banner
瑞瑞蓝

瑞瑞蓝

你的气质里,藏着你读过的书、走过的路和爱过的人。 feedId:52379216682516491+userId:41405500948898816
email
x
tg_channel
github
jike
steam

Markdown Example - How to Get Started with Markdown Quickly

Markdown Example - How to Get Started with Markdown#

This is an example article to test Markdown rendering.


1. Markdown Headings#

Markdown supports two types of heading syntax: Setext and Atx

1. Setext Syntax#

Setext syntax uses underlines with = (for highest level heading) and - (for second level heading)

For example:

Image.png

2. Atx Syntax#

Atx syntax uses 1 to 6 # at the beginning of the line to represent heading levels 1 to 6.

For example:

# Heading 1
## Heading 2
### Heading 3
#### Heading 4
##### Heading 5
###### Heading 6

Image.png

Headings are frequently used in Markdown, and you can choose the syntax that suits your preference. However, most software supports the second type of heading style using #, while the first type is less commonly used.

2. Blockquotes#

Blockquotes are created using the email-style '>' angle brackets.

For example:
> Quote
> 
> > Nested Quote
>
> ## Heading in Quote

Quote

Nested Quote

Heading in Quote#

Markdown uses asterisks and underscores to mark emphasized text. A single mark represents italics, while double marks represent bold.

For example:
Using single asterisks: *Italic with asterisks*
Using single underscores: _Italic with underscores_
Using double asterisks: **Bold with asterisks**
Using double underscores: __Bold with underscores__
Strikethrough: ~~Strikethrough~~
  • Using single asterisks: Italic with asterisks
  • Using single underscores: Italic with underscores
  • Using double asterisks: Bold with asterisks
  • Using double underscores: Bold with underscores
  • Strikethrough: Strikethrough

3. Unordered Lists#

Unordered lists use asterisks (*), plus signs (+), or hyphens (-) as item markers.

Asterisk, plus, hyphen:
* Candy.
+ Gum.
- Booze.
  • Candy.
  • Gum.
  • Booze.

4. Ordered Lists#

Ordered lists use numbers followed by a period as item markers. The numbers must be sequential, but the period and space after the number can be omitted.

1. Red
2. Green
3. Blue
  1. Red
  2. Green
  3. Blue

5. Nested Lists#

The symbols -, +, and * can be used in a nested manner. The symbols must be followed by a space, and the indentation can be achieved using tabs or four spaces.

- Nested list 1
+ Nested list 1a
+ Nested list 1b
- Nested list 1ai
	* Nested list 1aix
	- Nested list 2
  • Nested list 1
    • Nested list 1a
      • Nested list 1ai
        • Nested list 1aix
    • Nested list 1b
  • Nested list 2

Three or more -_* must be on a separate line and can contain spaces. (Note: If --- is used after text, it becomes a subheading.)

Additionally, if you have multiple levels in ordered or unordered lists, you can use Tab and Shift + Tab to indent and unindent.

In Markdown, you can insert links using the syntax [display text](link address). For example:

Text link: [GitHub](http://www.github.com)
Reference link:
[Google][1] [1]:http://www.google.com
Automatic link: http://www.google.com 
Email link: <[email protected]>

Text link: GitHub

Reference link: Google

Automatic link: http://www.google.com

Email link: [email protected]

In Markdown, you can insert images using the syntax ![image](https://example.jpg). For example:

![Example](https://cdn.hashnode.com/res/hashnode/image/upload/v1650872248441/srP9RSsrv.png)

Markdown Example

Note: The syntax for inserting images is similar to that of links, but with an additional ! at the beginning.

8. Code Blocks#

`code` (for short code snippets)
`Tab` or four spaces (for longer code blocks, add before each line)

code
Tab or four spaces

9. Large Code Blocks#

To create a large code block, surround your code with three backticks ` at the beginning and end. You can specify the programming language after the first line, or leave it unspecified.

@requires_authorization
def somefunc(param1='', param2=0):
    '''A docstring'''
    if param1 > param2: # interesting
        print 'Greater'
    return (param2 - param1 + 1) or None
class SomeClass:
    pass
>>> message = '''interpreter
... prompt'''

10. Special Characters#

Special characters can be escaped using a backslash \.

\\ Backslash
\` Backtick
\* Asterisk
\_ Underscore
\{\} Curly braces
\[\] Square brackets
\(\) Parentheses
\+ Plus sign
\- Minus sign
\. Period
\! Exclamation mark
  • \ Backslash
  • ` Backtick
  • * Asterisk
  • _ Underscore
  • {} Curly braces
  • [] Square brackets
  • () Parentheses
  • + Plus sign
  • - Minus sign
  • . Period
  • ! Exclamation mark

11. Tables#

  • Use | to separate different cells and - to separate the header from other rows:
name | age
---- | ---
LearnShare | 12
Mike | 32
nameage
LearnShare12
Mike32
  • To align cells in different rows for better appearance, use spaces and | on both sides to mark cell boundaries:
| name       | age |
| ---------- | --- |
| LearnShare | 12  |
| Mike       | 32  |
nameage
LearnShare12
Mike32
  • To specify the alignment of cell contents below the header, add : to the separator line:
| left | center | right |
| :--- | :----: | ----: |
| aaaa | bbbbbb | ccccc |
| a    |   b    |     c |
leftcenterright
aaaabbbbbbccccc
abc

12. Horizontal Rule#

---

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.