treant-js
                                
                                 treant-js copied to clipboard
                                
                                    treant-js copied to clipboard
                            
                            
                            
                        Simple onclick function
I am using treant within Angular, and am having a time getting an event handler on a node.
can you add a onClick, onExpand, and onCollapse callback function? even just an onCLick so I can examine the nodes expanded state would do the trick.
I would like to add the functionality to edit/add/delete nodes and to do that I need to be able to capture the "id" of the node. I can capture Treant's id, but I need the primary key of the record I am updating.
Are you using Treant with Angular1.x, or Angular2?
Are you passing a reference to jQuery ($) in the constructor?
var my_chart = new Treant( chart_structure, callback, $ ); 
From the docs: "jQuery is an optional parameter. If jQuery is available simply pass $ for this parameter. This will provide animation support, ability to get TreeNode class instances directly from the DOM using .data( 'treenode' );, and many more features."
Not sure if that helps. I'm using Treant in an Angular2 project, and I'd also like some additional hooks, but I'm not sure how active the development on this library is.
Have anybody was able to figure that out, is this possible? Tnx