Collapse/expand child nodes of tree in d3.js?
问题 I'm building a tree structure (or rather modifying one of the examples with a set of my own data in my own json) and I'm trying to create some functionality: My tree's layout is that from the tree example: http://mbostock.github.com/d3/ex/cluster.html I am adding (to the circles) an onclick event which I would like to collapse the children of the clicked node. That is to say, when a user clicks the steelblue circle associated with a node, I want that nodes children to disappear. I've scoured