source: node_modules/d3-hierarchy/src/hierarchy/links.js@ a762898

Last change on this file since a762898 was e4c61dd, checked in by istevanoska <ilinastevanoska@…>, 6 months ago

Prototype 1.1

  • Property mode set to 100644
File size: 246 bytes
Line 
1export default function() {
2 var root = this, links = [];
3 root.each(function(node) {
4 if (node !== root) { // Don’t include the root’s parent, if any.
5 links.push({source: node.parent, target: node});
6 }
7 });
8 return links;
9}
Note: See TracBrowser for help on using the repository browser.