Home > Archives > Markdown解析器redcarpet

Markdown解析器redcarpet

Publish:

redcarpet and extensions

传送门

安装

gem install redcarpet

如果是 Linux 需要 root 权限. sudo gem install redcarpet

使用

修改_config.yml 中的 markdown 属性为 redcarpet.

属性

需要打开 redcarpet中的插件以支持其特殊 markdown 语法

Tables Are Cool
col 3 is right-aligned $1600
col 2 is centered $12
zebra stripes are neat $1

配置

_config.yml 中增加redcarpetextensions选项:

# extensions of redcarpet
redcarpet:
  extensions: ["no_intra_emphasis", "fenced_code_blocks", "autolink", "tables","with_toc_data","strikethrough","underline","superscript"]
# more(http://chaoskeh.com/blog/markdown-and-redcarpet.html)
# more(https://github.com/vmg/redcarpet)

warning

坑死爹了,找了半天才明白


其他 markdown 解析器

声明: 本文采用 BY-NC-SA 授权。转载请注明转自: Tao Chiang