Skip to main content
100%

Let's make a map with D3.js!

✓ Published0🌍 Public
JJovenne Naldrey Sapuay
Last edited Sep 4, 2019
Created on Sep 4, 2019

This example shows a world map rendered as SVG paths, with countries filled in tomato red against a yellow sphere background. It uses the Natural Earth projection via `d3.geoNaturalEarth1` and `d3.geoPath` to generate the geographic outlines. The code loads TopoJSON country boundaries from the world-atlas package and converts them to GeoJSON using the `feature` method from `topojson`. A single sphere path is drawn first, followed by country paths, with strokes for borders. The map is static, with no interactivity or zoom.

AI-generated description
MIT Licensed

Similar vizzes