table content provider
blackstork/builtin, v0.4.2
Description #
Renders a table.
Each cell template has access to the data context and the following variables:
.rows– the value ofrowsargument.row.value– the current row from.rowslist.row.index– the current row index.col.index– the current column index
Header templates have access to the same variables as value templates,
except for .row.value and .row.index
The table content provider is built into the BlackStork engine. It is available out-of-the-box and requires no installation or dependency declaration.
Configuration #
This content provider does not accept any configuration arguments.
Usage #
This content provider accepts the following arguments within a content table block:
content table {
# A list of objects representing rows in the table. Can be a static list or `query_jq()` func call.
#
# Optional list of jq queriable.
# Default value:
rows = null
# List of a header and a cell template pairs for each column
#
# Required list of object.
# Must be non-empty
#
# For example:
columns = [{
header = "1st column header template"
value = "1st column value template"
}, {
header = "2nd column header template"
value = "2nd column value template"
}]
}