[improvement] Badge: jsx (#2440)

This commit is contained in:
neverland
2019-01-05 15:44:27 +08:00
committed by GitHub
parent 1468f9e210
commit de9c7ffe0a
3 changed files with 28 additions and 47 deletions
@@ -1,13 +1,3 @@
<template>
<div
:class="b()"
class="van-hairline--top-bottom"
>
<slot />
</div>
</template>
<script>
import create from '../utils/create';
export default create({
@@ -30,6 +20,13 @@ export default create({
return {
badges: []
};
},
render(h) {
return (
<div class={['van-hairline--top-bottom', this.b()]}>
{this.$slots.default}
</div>
);
}
});
</script>