2024-07-16 15:24:41 +08:00

27 lines
452 B
Vue

<template>
<div :class="className" :style="style" ref="container"></div>
</template>
<script setup>
import { Pie } from "@antv/g2plot";
// hooks
import useChart from "./useChart";
const props = defineProps({
className: {
type: String,
default: "",
},
style: {
type: Object,
default: () => ({}),
},
config: {
type: Object,
default: () => ({}),
},
});
const { container } = useChart(Pie, props.config);
</script>