mirror of https://github.com/sveltejs/svelte
15 lines
344 B
15 lines
344 B
<script>
|
|
function handleTouchstart() {
|
|
// ...
|
|
}
|
|
|
|
function handleClick() {
|
|
// ...
|
|
}
|
|
</script>
|
|
|
|
<div on:touchstart={handleTouchstart}>
|
|
<button on:click|stopPropagation|preventDefault={handleClick}>click me</button>
|
|
<button on:click|once|capture={handleClick}>or me</button>
|
|
<button on:click|capture={handleClick}>or me!</button>
|
|
</div> |