markdown

Author Avatar
LI Liangmin 9月 15, 2017

Brief Introduction of MarkDown

It is common that we have to write a passage, but so many times
we are in the troubles of nice arrangement of style.

MarkDown is a way to solve the problem, what we need is only simple
hints. Let’s begin the study of MarkDown.


General Description

  1. if there is a block element, we need two blanks before and after the
    contents.

  2. if there is only a inline element, we need just write one by one.

  3. Indent. Indent have meanning of these: <pre></pre> or child element.

  4. if the sign has meaning in md , we have to use \ to eacape.

Block Element

  1. passage <p></p>
    According to general rule we only need two blanks before and after contents.

  2. line break <br />
    We can break the line personnally. Just two or more spaces at the end of line

  3. horizontal tags <hr />
    we put three or more signs as ----- or _____, but we need blanks

  4. blockquote <blockquote></blockquote>
    we need > or >> according structure. For example:

     >  This is demo of blockquote        
     >
     >> This is block inside the outer blockquote
     >
     >1. item1
     >   
     >   * unordered list 
    
  5. header <h1> <h2> <h3> <h4> <h5> <h6>
    we need # for <h1> and similar for the others.

  6. ordered list <ol>
    we use just number. if we do need a number like 12. 32, we need \
    to escape like 12\. 32.

  7. unorder list <ul>
    we can use + or - or *;

  8. code block <pre></pre>
    Indent every line of the block by at least 4 spaces or 1 tab.

  9. fenced code block
    As I use in the article, just use ``content`` or ```content```

  10. table <table></table>

    |name |age  |address|
    |:---:|:---:| :---: |   // : means way of alignment
    |lee  | 25  | Wuhan |
    

Inline Elements

  1. ordinary link <a></a>
    we use like this [link text](url 'optional title') or [link text][id] [id]: url "optional text"

  2. image link ‘
    Same as orinary link except we use ! link ![alt text](url 'optional text')

  3. just url
    we just use as <http://mzlee.site> or <mailto: nucliliangmin@163.com>

  4. emphysis <em></em>or strong <strong></strong>
    one *content* means <em>content</em>, two means the last.

  5. strikethrough <del></del>
    we use ~~content~~, contnet

html tag

sure, we can use html tags as we usually. There is a problem : MarkDown is useless
when in block elements.