Tables
Use tables to structure information into rows and columns for easy comparison. For example, to compare features in different editions of a product or to document the responsibilities of different roles.
To insert a table, use the <table>
element, add rows using <tr>
, and cells using <td>
.
By default, Writerside renders tables with the first row as the header. Use the style
attribute to change the table header.
style="header-row"
is the default value, which renders the table with a header row at the top:
Column Name | Column Name | Column Name |
---|---|---|
Lorem ipsum dolor sit amet | Consectetur adipiscing elit | Mauris feugiat euismod sapien at iaculis |
Set style="header-column"
to render the table with the first column as the header:
Row Name | Lorem ipsum dolor sit amet | Consectetur adipiscing elit |
---|---|---|
Row Name | Mauris feugiat euismod sapien at iaculis | Sed vel turpis quam |
Set style="both"
to render both a header row and a header column:
Column Name | Column Name | |
---|---|---|
Row Name | Lorem ipsum dolor sit amet | Consectetur adipiscing elit |
Row Name | Mauris feugiat euismod sapien at iaculis | Sed vel turpis quam |
Set style="none"
to render the table without headers:
Consectetur adipiscing elit. | Lorem ipsum dolor sit amet. |
Mauris feugiat euismod sapien at iaculis | Sed vel turpis quam |
Markdown tables
For simple tables in a Markdown file, use hyphens ---
to separate the header row, and pipes |
to separate each column.
Alternatively, press Alt+Insert to open the Insert menu, and then select Table to generate a Markdown table of any size.
![Insert table in Markdown Insert table in Markdown](https://resources.jetbrains.com/help/img/writerside/insert_md_table_popup.png)
Markdown tables have certain limitations. For example, they must always have a header row, you cannot break lines in cells, you cannot span a cell across multiple rows or columns. If you need a more complex table, use the <table>
element.
Convert Markdown table to semantic markup
With the caret inside the table, press Alt+Enter and select Convert Markdown table to XML format.