Closed jharris4 closed 8 years ago
Correct, d3.curveBundle is only intended to work with d3.line. It’s for hierarchical edge bundling, not for rendering areas. I’ll update the documentation accordingly.
awesome, thanks for clearing that up!
Was there any particular reason for reserving d3.curveBundle
to the interpolation of lines to the exclusion of areas, starting in v4?
Back in D3 v3, I could use it on areas as well (e.g.: .interpolate("bundle").tension(0)
).
FYI, I needed it in v4/v5 as well, so created a custom curve for it with some help from StackOverflow.
While trying out the various curves with an area shape generator I noticed that I get the following error when using the bundle curve:
Uncaught TypeError: output.areaStart is not a function
which occurs at this line of area.js
It works fine with the line generator, and I see that bundle-test.js doesn't have any tests for areas.
I guess this means bundle curves are only designed to work with lines?
In case you want a quick way to reproduce, I've attached a short example index_html.txt