mirror of https://github.com/sveltejs/svelte
add ssr for group bindings (#4621)
* add ssr for group bindings * remove unnecessary chunk length check * check if checkbox or radio Co-authored-by: tanhauhau <lhtan93@gmail.com>pull/6517/head
parent
ce43bd67c7
commit
7bcbe67939
@ -0,0 +1,5 @@
|
||||
<div>Cheese</div>
|
||||
<input type="radio" value="Plain" checked>
|
||||
<input type="radio" value="Whole wheat">
|
||||
<input type="checkbox" value="Beans">
|
||||
<input type="checkbox" value="Cheese" checked>
|
@ -0,0 +1,12 @@
|
||||
<script>
|
||||
let tortilla = 'Plain';
|
||||
let fillings = ['Cheese'];
|
||||
</script>
|
||||
|
||||
<div>{fillings.toString()}</div>
|
||||
|
||||
<input type="radio" bind:group={tortilla} value="Plain">
|
||||
<input type="radio" bind:group={tortilla} value="Whole wheat">
|
||||
|
||||
<input type="checkbox" bind:group={fillings} value="Beans">
|
||||
<input type="checkbox" bind:group={fillings} value="Cheese">
|
Loading…
Reference in new issue