Table
A bordered, horizontally scrollable shell around a native table. Write
normal thead/tbody markup; the cells are styled for
you.
Examples
Basic
| Name | Role | Status |
|---|---|---|
| Ada Lovelace | Engineer | active |
| Grace Hopper | Compiler team | away |
Show code
<Table caption="Team">
<thead>
<tr><th scope="col">Name</th><th scope="col">Role</th></tr>
</thead>
<tbody>
<tr><th scope="row">Ada Lovelace</th><td>Engineer</td></tr>
</tbody>
</Table>Props
| Prop | Type | Default | Description |
|---|---|---|---|
caption | string | — | Optional caption above the header row. |
children | Snippet | — | The thead and tbody rows, using normal table markup. |
Other attributes are spread onto the <table>, while class goes on the scroll wrapper. Cell styles are scoped under .table, so they cannot leak into the rest of your app.