World Countries Tree-labels
✓ Published0🌍 Public
This example shows a hierarchical tree layout of world countries, organized by continent and subregion, with each country name displayed as a text label. The visualization uses D3 v6’s `tree` layout and `linkHorizontal` path generator to draw curved links between parent and child nodes. Labels are rendered as SVG `<text>` elements with font sizes decreasing by depth, and a D3 `zoom` behavior enables panning and scaling. The data is loaded from a local JSON file, and white text shadows improve readability over the drawn paths.
AI-generated descriptionAn example including some commonly used features of SVG.
MIT Licensed