mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 12:14:41 +01:00
Co-authored-by: Daniel Roe <daniel@roe.dev> Co-authored-by: Sébastien Chopin <seb@nuxt.com>
12 lines
210 B
Vue
12 lines
210 B
Vue
<script setup>
|
|
const toast = useToast()
|
|
|
|
function onClick () {
|
|
alert('Clicked!')
|
|
}
|
|
</script>
|
|
|
|
<template>
|
|
<UButton label="Show toast" @click="toast.add({ title: 'Click me', click: onClick })" />
|
|
</template>
|