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

18 lines
207 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>