You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte/test/runtime/samples/binding-select-in-yield/main.svelte

16 lines
318 B

<script>
import Modal from './Modal.svelte';
export let modal;
export let letter;
export let letters = ['a', 'b', 'c'];
</script>
<Modal bind:this={modal}>
<span>{letter}</span>
<select bind:value={letter}>
{#each letters as letter}
<option value="{letter}">{letter}</option>
{/each}
</select>
</Modal>