Blockquotes Syntax and example markdown

Blockquotes allows having a part of the content from another source link. These are similar to reply email text.

Add the symbol greater than ‘>’ to the line that contains the text.

After the symbol, there is an optional space.

> This is blockquote text

Generated Html

<blockquote>
    <p>This is blockquote text</p>
</blockquote>

and Rendered output

This is blockquote text

Nested blockquotes markdown

blockquotes can be inside other blockquotes, called nested.

>> symbol used to represent the starting of the line or paragraph.

> This is blockquote text
> This is the second line of text
>> This is nested blockquotes content

and output displayed on the browser is

This is blockquote text This is indent space text

This is nested blockquotes content

blockquotes with multiple lines of text in Markdown

These can contain multiple lines or paragraphs by adding the ‘>’ symbol. Also, include empty lines.

> line one text1
>
>This is paragraph text2

output is

line one text1

This is paragraph text2

paragraph with multiple lines in Markdown

> This is a blockquote example of writing multiple lines in a single paragraph.

Output is

This is a blockquote example of writing multiple lines in a single paragraph. Quoting your text example

markdown can contain formatted elements

Also, blockquotes can contain other markdown elements.

The following example contains formatted styles.

  • Headings
  • Emphasis bold, italic
  • Strikethrough
  • Code block
> #### Heading in blockquotes text
> **bold text**
> _italic text_
> ~~strikethrough text~~
> `code element`

Output

Heading in blockquotes text

bold text

italic text

strikethrough text

code element

markdownSyntax highlight

Also, code can contain blockquotes. Following is a Java program code inserted with syntax highlighter.

> HelloWorld.java:
>
> ```java
> class HelloWorld {
>    public static void main(String[] args) {
>       System.out.println("Simple hello world program");
>   }
>}
>

Output is

HelloWorld.java:

class HelloWorld {
   public static void main(String[] args) {
      System.out.println("Simple hello world program");
  }
}