dash14 / v-network-graph

An interactive network graph visualization component for Vue 3
https://dash14.github.io/v-network-graph/
MIT License
485 stars 44 forks source link

Support add and remove edge between nodes on graph -- suggested feature #90

Closed hellofreckles closed 1 year ago

hellofreckles commented 1 year ago

Nice job!

I would like to add an edge between two nodes on the graph (not by update data) when I add a new node.

dash14 commented 1 year ago

Hi @hellofreckles,

Thanks for the feature suggestion! Let me ask a few questions to understand your suggestion. As shown in the example below, it is still possible to add nodes and edges by updating the data at any time the application needs them. https://dash14.github.io/v-network-graph/examples/operation.html#add-remove-network-elements

Since you write "not by update data" do you want to add nodes or edges in a different way than above? Currently, v-network-graph only displays graph structures (node and edge) as specified from outside the library, and does not support the ability to modify graph structures from the library. Therefore, I would like to be cautious about features that modify the graph structure other than updating the data.

Here are my questions:

  1. Please tell use cases. Is it something that cannot or is difficult to achieve by updating the data?
  2. What are the specific processes/results/behaviors you expect from the suggested feature?
    • ex: Event notifying that a new node has been added.
    • ex: A function that takes two node IDs as input and connects an edge between them. (However, this can be accomplished by updating the data.)

Best Regards

dash14 commented 1 year ago

Since no response was received, the issue is closed for now.. If you have any comment, please reopen this issue.