I'm using the following code:
https://bl.ocks.org/adamfeuer/042bfa0dde0059e2b288
And am loading a very simple json string to create the tree:
{
"name": "flare",
"children": [{
"name": "analytics"
}, {
"name": "animate"
}]
}
So what I'm trying to figure out is that after I add a new child node to the "flare" node (for example), how can I create an updated json string in order to save the newly added node?
An example of the updated json after adding a new node would be like so:
{
"name": "flare",
"children": [{
"name": "analytics"
}, {
"name": "animate"
}, {
"name": "NEW NODE"
}]
}
Is there some built in function for this that I am not finding? Or would a custom function have to be built? And if I need a custom function could somebody please point me in the right direction to do so? Thank you very much!