Svelte adapter ยท console.warn
LatticeTabs: `tabs` changed (a label, a badg...
Printed by Svelte adapter, prefixed [lattice], since 1.66.0.
Warnings reference › svelte.tabs.mountOnly.tabs
- Identifier
svelte.tabs.mountOnly.tabs- Raised by
- Svelte adapter
- Since
- 1.66.0
What happened
The Svelte tabs component received a different tabs array from the one the strip was built with. As in every adapter, the tabs module reads the descriptors once; there is no API to repaint a built tab, so nothing could be applied, and the strip was left alone rather than being rebuilt behind your back and closing the open tab.
The fix
Toggle an {#if} or {#key} around the strip when you genuinely want a new one. A badge that has to track live data belongs in your own markup, outside the strip.
The smallest fix
{#key tabsRevision}
<LatticeTabs {tabs} bind:active />
{/key}
Reference
Covered in full at the API reference.