require d3 in main and remove from index