mirror of
https://github.com/youzan/vant.git
synced 2025-10-18 09:24:25 +00:00
badge unit test
This commit is contained in:
24
test/unit/components/badge.vue
Normal file
24
test/unit/components/badge.vue
Normal file
@@ -0,0 +1,24 @@
|
||||
<template>
|
||||
<zan-badge-group>
|
||||
<zan-badge title="热销榜" info="8" @click="onItemClick"></zan-badge>
|
||||
<zan-badge title="手握寿司" info="199" @click="onItemClick"></zan-badge>
|
||||
</zan-badge-group>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Badge from 'packages/badge';
|
||||
import BadgeGroup from 'packages/badge-group';
|
||||
|
||||
export default {
|
||||
components: {
|
||||
'zan-badge': Badge,
|
||||
'zan-badge-group': BadgeGroup
|
||||
},
|
||||
|
||||
methods: {
|
||||
onItemClick() {
|
||||
console.log('click');
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
Reference in New Issue
Block a user