Table is a html element which organizes information into rows and column.
Output:
title1 | title2 | title3 |
---|---|---|
title1 | title2 | title3 |
Code:
<div class="darkout-section">
{% include do-table.html tag="sample" %}
</div>
_data > do-table.yml
do-table:
- table:
- row: # Use table title on this array
- data: title1 # Use data here
- data: title2
- data: title3
- row:
- data: title1
- data: title2
- data: title3
tag: sample
Step3: In the data file tag is a mandatory value. Without using tag table will not be displayed.
Step4: In the data file first ‘row’ array will be used for table heading(th).
Step2: On the page use
<div class="darkout-section">{% include do-table.html tag="sample" %}</div>