We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
我之前提过这个问题。。你说没问题。。但是真的真的有问题
this.ganttData = undefined setTimeout(() => { this.ganttData = { data, links } }, 100)
<x-gantt v-if="data" :data="data.data" :links="data.links"
// this.ganttData = undefined
The text was updated successfully, but these errors were encountered:
code pls
Sorry, something went wrong.
<script setup> import { ref } from 'vue' const data = ref({ data: [], links: [] }) function randInt(a, b) { return a + Math.floor(Math.random() * (b - a)) } function updateData() { const data2 = { data: [], links: [] } const N = randInt(10, 20) for (let i = 0; i < N; i++) { const a = randInt(1, 10) const b = a + randInt(1, 10) data2.data.push({ id: i, name: `task ${i + 1}`, startDate: new Date(2024, 5, a), endDate: new Date(2024, 5, b) }) data2.links.push({ from: i, to: i + 1 }) } data.value = data2 } setInterval(() => { //data.value = undefined setTimeout(updateData, 100) }, 1000) </script> <template> <x-gantt v-if="data" :data="data.data" :links="data.links"> <x-gantt-column prop="name" /> <x-gantt-column prop="startDate" date-format="MM/DD" /> <x-gantt-slider /> </x-gantt> </template>
fix: 连线缺失监听
8ece20a
fix #102 #108
3ad16b3
jeremyjone
No branches or pull requests
我之前提过这个问题。。你说没问题。。但是真的真的有问题
links 数据改变之后 真的会渲染有问题 (消失)
我目前的 work around, 通过 v-if 使整个组件重新渲染
如果不使用上面的 work around
// this.ganttData = undefined
The text was updated successfully, but these errors were encountered: