mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-19 11:59:34 +00:00
refactor(data-table): remove unused indices
This commit is contained in:
parent
e600115ecc
commit
4b8130befd
1 changed files with 2 additions and 2 deletions
|
@ -148,7 +148,7 @@
|
||||||
const tableRows = writable(rows);
|
const tableRows = writable(rows);
|
||||||
const thKeys = derived(headerItems, () =>
|
const thKeys = derived(headerItems, () =>
|
||||||
headers
|
headers
|
||||||
.map(({ key }, i) => ({ key, id: key }))
|
.map(({ key }) => ({ key, id: key }))
|
||||||
.reduce((a, c) => ({ ...a, [c.key]: c.id }), {})
|
.reduce((a, c) => ({ ...a, [c.key]: c.id }), {})
|
||||||
);
|
);
|
||||||
const resolvePath = (object, path) => {
|
const resolvePath = (object, path) => {
|
||||||
|
@ -339,7 +339,7 @@
|
||||||
/>
|
/>
|
||||||
</th>
|
</th>
|
||||||
{/if}
|
{/if}
|
||||||
{#each headers as header, i (header.key)}
|
{#each headers as header (header.key)}
|
||||||
{#if header.empty}
|
{#if header.empty}
|
||||||
<th scope="col" style="{formatHeaderWidth(header)}"></th>
|
<th scope="col" style="{formatHeaderWidth(header)}"></th>
|
||||||
{:else}
|
{:else}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue