🌍 Public
Viewing a saved revision (read-only)
0baa25c12e8342c98a87aef5c5954b19
Activity 8 Country
This example displays a map of India rendered as an SVG path, centered using a Mercator projection fitted to the country’s geographic bounds. The code loads world country boundaries from the World Atlas TopoJSON collection via `d3.json`, extracts the India feature using `topojson.feature`, and draws it with `d3.geoPath`. The projection is created with `d3.geoMercator` and sized to a 960 by 500 viewport, demonstrating how to subset and visualize a single country from global geospatial data.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.