Error message, as shown in the figure:
ask
nodes: [
{
id: 1, // Change it to id: '1' and it will be solved
label: 'Initiated by Beijing and Hangzhou'
}
],
edges: [
{
id: 'edge1',
target: 'node2',
source: 'node1'
}
]
The fundamental point of the question is that the Id in nides and edges must be of type String
Does it feel very simple? Or should you read more API documentation?