define d3-graph as a module