Nuxt/examples/jest-vtu-example/components/Btn/Btn.vue

26 lines
327 B
Vue
Raw Normal View History

<template>
<button @click="handleClick">
{{ label }}
</button>
</template>
<script>
export default {
name: 'Button',
props: {
label: {
type: String,
required: true
}
},
data: () => ({
clicked: false
}),
methods: {
handleClick() {
this.clicked = true
}
}
}
</script>