MCPcopy Create free account
hub / github.com/SeaOfNodes/Simple / addToNodeDictionary

Function addToNodeDictionary

chapter18/docs/d3-graphviz.js:1097–1112  ·  view source on GitHub ↗
(datum)

Source from the content-addressed store, hash-verified

1095 });
1096 }
1097 function addToNodeDictionary(datum) {
1098 var tag = datum.tag;
1099 if (growEnteringEdges && datum.parent) {
1100 if (datum.parent.attributes["class"] == 'node') {
1101 if (tag == 'title') {
1102 if (datum.children.length > 0) {
1103 var child = datum.children[0];
1104 var nodeId = child.text;
1105 } else {
1106 var nodeId = '';
1107 }
1108 nodeDictionary[nodeId] = datum.parent;
1109 }
1110 }
1111 }
1112 }
1113 function extractGrowingEdgesData(datum) {
1114 var id = datum.id;
1115 var tag = datum.tag;

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected