泰晓科技 -- 聚焦 Linux - 追本溯源,见微知著!
网站地址:http://tinylab.org
请稍侯

[ 点 我 解 锁 ]

加微信 tinylab 进本站 Linux 交流群。

搜索 泰晓科技 或扫码关注本站公众号。

Use tables in Pandoc's Markdown

Wu Zhangjin 创作于 2014/01/11

by Falcon of TinyLab.org 2014/01/11

Issue

The standard Markdown allows to add tables in HTML format, for exampe:

<table>
 <tr>
   <th>
     Head row1
   </th>
   <th>
     Head row2
   </th>
 </tr>
   
 <tr>
   <td>
     Content row1
   </td>
   <td>
     Content row2
   </td>
   
 </tr>
</table>

And it looks like:

Head row1Head row2
Content row1Content row2

But Pandoc doesn’t support it, Pandoc need pure text table, see the Tables section in Pandoc’s User Guide.

Solution

So, to make a table work with pandoc, we must use something like:

Head row1         Head row2
----------------  ----------------
  Content row1      Content row2

Read Album:

Read Latest: