-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
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
vue3按照官网给的例子,使用x6-vue-shape渲染节点,报错,使用的都是模板的代码 #3624
Comments
Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. |
我也是这个问题,按照官方文档写的。但是就是报错 |
https://x6.antv.antgroup.com/tutorial/intermediate/vue |
使用文档 上的方法来注册节点,而不是使用 |
import { register, getTeleport } from '@antv/x6-vue-shape' register({ |
This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread. |
Describe the bug
报这个错::Uncaught TypeError: Cannot destructure property 'component' of 'shapeMaps[node.shape]' as it is undefined.,不知道怎么解决使用
Your Example Website or App
import Count from 'Count.vue' const graph = new Graph({ container: document.getElementById("app"), width: 600, height: 400, grid: true, }); Graph.registerNode("my-count", { inherit: "vue-shape", x: 200, y: 150, width: 150, height: 100, component: { template:
<Count />
, components: { Count, }, }, }); graph.addNode({ id: "1", shape: "my-count", x: 400, y: 150, width: 150, height: 100, data: { num: 0, }, });Steps to Reproduce the Bug or Issue
报这个错::Uncaught TypeError: Cannot destructure property 'component' of 'shapeMaps[node.shape]' as it is undefined.
Expected behavior
初始化的时候,就直接无法初始化
Screenshots or Videos
No response
Platform
x6使用的是2.11.1的版本
x6-vue-shape使用的是2.0.11版本
Additional context
No response
The text was updated successfully, but these errors were encountered: