Using D3 libraries
This usually ends in disaster for one simple reason: the product is immensely complex due to its strictly data-driven design. Think of a D3-based diagram like a ‘shell’ of <div> tags animated via data binding – an architecture as powerful as it is difficult to tame.
Should you feel like using D3.js in anger, an interesting approach involves the use of pre-made D3 libraries such as C3 found at https://c3js.org. They act as a ‘wrapper’ around the underlying D3 library and provide an easy-to-use interface not dissimilar to the one in Chart.js.