GitHub Page使用的Jekyll有所謂的Front Matter,可以在文章裡面加上如下的Yaml設定, 客製化文章一些資料, 比如說 layout, title, tag, date 等. 如果不指定則像是文章名稱會預設用檔名(字首大寫). E.g. 2016-01-01-文章名.md. posts資料夾裡的文章檔名一定要帶有時間,
---
title: "It is a cat."
---
正文開始,最好與上面的Yaml空一行,不然有時排版會亂掉.
若要測試寫好的.md/.markdown檔,若要100%確定效果,可以
換一個段落的方法
inline code block:使用兩個前導字元包起來,e.g.
`test`
multiple line code block, 可使用四個空白 或是`(Fenced code blocks)的做法, 參考https://help.github.com/articles/creating-and-highlighting-code-blocks/
語法高亮度的清單(不確定正確): https://github.com/jneen/rouge/wiki/List-of-supported-languages-and-lexers, https://github.com/github/linguist/blob/master/lib/linguist/languages.yml, 有人說別的Blog(e.g. Hexo)所使用的Markdown沒有支持Github用的`jascript這種
https://kramdown.herokuapp.com/ 沒有支援ES6的語法高亮度.
在 code block or inline code 中打出 ` 符號的方法. http://stackoverflow.com/questions/33224686/how-to-render-triple-backticks-as-inline-code-block-in-markdown, So I’ve found that using 4 backticks as opening and closing deliminators does the trick:
GitHub Pages and some/all markdown files on GitHub can accept these two types and show correctly. But this atom package only handles Kramdown type(~). Please keep in mind, and my opinion is to use ~. Also They both support non-fenced standard code block (4 indent) and single line code span.