使用typora实现表格单元格合并

Unfortunately, standard Markdown syntax does not support merging cells or having a single value span multiple rows or columns in a table. If you want to have a single value span multiple rows or columns, you will need to repeat the value in each cell.

However, some Markdown parsers and editors, including Typora, support the use of HTML within Markdown documents. This means that you can use HTML table syntax to create more complex tables with merged cells or cells that span multiple rows or columns. Here’s an example:

<table>
  <tr>
    <th>Header 1</th>
    <th>Header 2</th>
    <th>Header 3</th>
  </tr>
  <tr>
    <td>Row 1, Column 1</td>
    <td rowspan="2">Same Value</td>
    <td>Row 1, Column 3</td>
  </tr>
  <tr>
    <td>Row 2, Column 1</td>
    <td>Row 2, Column 3</td>
  </tr>
</table>
Header 1Header 2Header 3
Row 1, Column 1Same ValueRow 1, Column 3
Row 2, Column 1Row 2, Column 3
This will create a table that looks like this:

Header 1 Header 2 Header 3
Row 1, Column 1 Same Value Row 1, Column 3
Row 2, Column 1 Row 2, Column 3
In this example, we used the rowspan attribute to specify that the cell with the value “Same Value” should span two rows.

Is there anything else you would like to know about creating tables in Typora using HTML syntax?

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值