"MarkDown" uses HTML style and collapsed syntax

Source: Internet
Author: User

Markdown is convenient, but the basic syntax is somewhat inadequate: such as the inability to use the folding grammar, the text can not have a different color.

These features can be implemented, but need to be extended using HTML syntax. This article is mainly to tidy up these skills, convenient and better use.

First, the folding syntax: <details>Tag 1.1, Code:
<details>  <summary>点击时的区域标题:点击查看详细内容</summary>  <p> - 测试 测试测试</p>  <pre><code>  title,value,callBack可以缺省  </code>  </pre></details>

summary: Summary of collapsed grammar presentation

details: Collapse Grammar Tags

pre: The text in the original format that displays the element is formatted.

blockcode: Represents a code block for a program.

code: Specifies the code example.

1.2, the actual effect:


Area title when clicked: Click to view Details

-Test test test


  title,value,callBack可以缺省    

Second, other HTML syntax: 2.1 Source:
<span style=‘color:red‘>This is red</span>   //字体颜色<ruby> 漢 <rt> ㄏㄢˋ </rt> </ruby> // 特殊字<kbd>Ctrl</kbd>+<kbd>F9</kbd>  // 按键标识<span style="font-size:2rem; background:yellow;">**Bigger**</span> //字体大小和背景<font face="微软雅黑" color="red" size="6">字体及字体颜色和大小</font><font color="#0000ff">字体颜色</font><p align="left">居左文本</p><p align="center">居中文本</p><p align="right">居右文本</p>

Use span or font label, and style control the style with attributes.

2.2 Actual effect:

This is red

Hans ㄏㄢˋ
Ctrl+F9

Bigger

Font and font color and size
Font Color

Left text

Center text

Right-of-abode text

Iii. Sources of reference:
  1. Markdown Embedding Folding Tags | The more https://www.sunyazhou.com/2017/10/25/20171025markdown-skill/the East Gold
  2. Let your MD document be folded and displayed · Issue #155 · Iuap-design/blog https://github.com/iuap-design/blog/issues/155 (feeling better than the last)
  3. HTML support in Typora https://support.typora.io/HTML/#html-entities (other HTML syntax and usage)
  4. Common syntax for markdown (personal summary) | Connorlin ' s Blog http://connorlin.github.io/2016/05/06/Markdown%E7%9A%84%E5%B8%B8%E7%94%A8%E8%AF%AD%E6%B3%95 (%e4 %B8%AA%E4%BA%BA%E6%80%BB%E7%BB%93)/

"MarkDown" uses HTML style and collapsed syntax

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.