Invalid List-Table Structure
::: {.list-table} div does not contain a well-formed list-table source, so Quarto cannot convert it into a table.
Q-2-35 — Invalid List-Table Structure
A
::: {.list-table}div does not contain a well-formed list-table source, so Quarto cannot convert it into a table.
What this means
Quarto’s recommended way to write tables is a list-table: a
fenced div with class list-table whose body is a nested
markdown list, where each top-level list item is a row and each
nested list item is a cell.
This error fires when the parser finds a list-table div but
its body is not a list at all, or its list does not have the
structure a list-table requires (rows with consistent cell
counts).
Why this happens
Common shapes that trigger the error:
- The body is plain text, not a list.
- The body is a list, but rows have different numbers of cells.
- Nesting is wrong — the cells are listed at the same level as the rows.
The same check runs on a list-table div that an {lmd} cell
builds from nodes (pandoc.Div({ … }, pandoc.Attr("", {"list-table"}))),
or that pandoc.read returns. A node built in a cell has no
position of its own in the document, so the warning then points at
the cell’s code and says the node was built there.
How to fix
Restructure the body so that each top-level list item is a row and each nested list item is one cell:
::: {.list-table}
- - Header 1
- Header 2
- - Cell A
- Cell B
- - Cell C
- Cell D
:::
Use exactly the same number of cells in every row.