Skip to main content
100%

World Map with D3.js!

✓ Published31🌍 Public
SSonuSriN
Last edited Apr 3, 2022
Created on Mar 30, 2022

This example shows a simple world map rendered as an SVG, with countries filled in green and a blue sphere background. Hovering over a country highlights it in orange. It uses d3.geoPath with the d3.geoEquirectangular projection to draw the map, and TopoJSON’s feature method to convert country boundaries from the world-atlas dataset. The code selects the SVG element, appends a sphere path, then joins country features to path elements.

AI-generated description
MIT Licensed

Similar vizzes