Need a hand on a conditional to see if my table has any data, and if it does, output the table. The second thing I need help is the code to output the table. When I look at tutorials, they always seem to output the table as an HTML list. Like:
{% if block.codePoints | length %}
<ul>
{% for row in block.codePoints %}
{# Assuming 'text' is the column handle of the text field #}
<li>{{ row.text }}</li>
{% endfor %}
</ul>
{% endif %}
I can't find an example of:
<table>
<tr><td></td><td></td><td></td></tr>
</table>
Thanks.
block
a Matrix block? If so, what type of field iscodePoints
? Or isblock
the name of an entry andcodePoints
is a table field?