{#key tabs} {#each tabs as tab (tab.title)} {#if tab.visible} {/if} {/each} {#each tabs as tab (tab.title)} {#if tab.visible} Content for {tab.title} {/if} {/each} {/key}
Selected index: {selected}