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/documentation/examples/14-classes/01-class-shorthand/App.svelte

19 lines
212 B

<script>
let big = false;
</script>
<label>
<input type="checkbox" bind:checked={big} />
big
</label>
<div class:big>
some {big ? 'big' : 'small'} text
</div>
<style>
.big {
font-size: 4em;
}
</style>