Render a table of objects with configurable, linkable columns.
ObjectTable renders a table of the objects matching the YAML filter, with configurable
columns. A column with link: true (e.g. id) becomes a clickable link to the object
page. When columns is omitted, the table defaults to a linked id column and a title
column.
Supported props
| Prop | Type | Required | Default | Purpose |
|---|---|---|---|---|
model_key | string | yes* | current route model | Which model to read |
children | YAML text/code block | no | id + title columns | filter + columns |
* Set model_key explicitly on specs pages.
Columns
Each column is { field, link?, label? }. Column order follows the config.
| Key | Type | Purpose |
|---|---|---|
field | string | Field name to show (id, title, type, …) |
link | boolean | When true, the cell links to the object page |
label | string | Custom header label (defaults to field) |
Example
Source syntax
<ObjectTable model_key="deployment">
```yaml
filter:
objects:
include:
id: ["iomodel.*"]
columns:
- { field: id, link: true }
- { field: title }
- { field: type }
```
</ObjectTable>Rendered output
No objects match this filter.
Common pitfalls
- Omitting
columnsfalls back toid(link) +title - Use
labelto give a column a friendly header - For non-tabular output, use
ObjectListorEach
Last updated on