World Countries Tree
✓ Published0🌍 Public
This visualization presents a hierarchical tree of world countries, organized by continent and subregion, using a left-to-right layout. The code employs D3 v5’s `tree` layout and `hierarchy` to structure the JSON data, while `linkHorizontal` draws the connecting paths. Text labels are positioned based on the tree’s node coordinates, with font size varying by depth. Pan and zoom functionality is implemented via D3’s `zoom` behavior on the SVG container. The styling uses a serif font and teal-colored links, with a white text shadow to improve label readability over the paths.
AI-generated descriptionMIT Licensed