Fork of Let's make a map with D3.js!
✓ Published0🌍 Public
This example shows a world map rendered with a natural Earth projection, displaying countries as light green polygons on a blue sphere. It uses D3 v5 with `d3.geoNaturalEarth1` for the projection and `d3.geoPath` to generate SVG paths from TopoJSON data loaded from the world-atlas package. The code appends a sphere outline and then iterates over country features, styling them with CSS classes that define fill and stroke properties. The map relies on the `topojson.feature` API to convert TopoJSON topology into GeoJSON features for rendering.
AI-generated descriptionMIT Licensed