Files
front/components/CardPreview.vue
T
2024-04-05 23:08:47 +02:00

23 lines
422 B
Vue

<script setup lang="ts">
const props = defineProps(['data'])
const cards = useState<{ [key: string]: any }>('cards')
function cardClick() {
console.log(JSON.parse(JSON.stringify(cards.value[props.data].effects)))
}
</script>
<template>
<span @click="cardClick">
{{ cards[props.data].name }}
</span>
|
</template>
<style scoped>
span {
border: 1px solid black;
cursor: pointer
}
</style>