Table - Row Controls

Back to Table Component Documentation

The table component can display controls before or after each row. Each control is defined by an icon name, a callback function, and optionally an HTML string or a render function. Use slot="before" to add the control before each row, and use slot="after" to add the control after each row.

<k-table id="rowControlsExample">
<k-tc-export-json slot="before" max-width="40">
<k-icon name="export-file"></k-icon>
</k-tc-export-json>
<k-tc-delete-record slot="after"></k-tc-delete-record>
</k-table>
<script type="module">
await window.customElements.whenDefined('k-table');
document.getElementById('rowControlsExample').setRecords(contacts);
</script>