markdown
There are other concepts named markdown. See the entire list.
markdown, data type
The markdown data type holds rich text formatted with Markdown. It supports
multi-line literals.
m = """Hello **World**"""
show markdown "" with m
Remarks
markdown values can exceed 256 characters and support interpolation.
Markdown values can be broadcast to tables, filtered inside where blocks, and
selected with conditional expressions. However, markdown values cannot be
unfiltered back to an outer scope once defined in a filtered scope.
Templated markdown literals (using \{...} inside a """ literal) are only
supported for scalar values or sliced values. Templated markdown is not allowed
inside user-defined functions.
table Items = extend.range(2)
Items.Tooltip = if Items.N == 1 then """First item""" else """Other item"""
show table "Items" with
Items.N
Items.N { cellTooltip: #[Items.Tooltip] }
Templated markdown literals
Templated markdown literals mix text and expressions inside a multi-line literal. Expressions are formatted as text and injected in place.
total = 42
md = """
Total quantity: \{total}
"""
show markdown "Summary" with md
For sliced dashboards, compute the markdown in the sliced table.
table T[id] = with
[| as id, as Qty |]
[| "a", 2 |]
[| "b", 5 |]
table Slices[slice] = slice by id title: T.id
expect Slices.id = same(id)
Slices.Qty = same(T.Qty)
total = sum(T.Qty)
Slices.Md = """
# \{Slices.id}
Qty: \{Slices.Qty}
Total: \{total}
"""
show markdown "Slice" slices: slice with Slices.Md