🌍 Public
Activity 8 Country
This example displays a map of India using a Mercator projection, rendered as an SVG path. It loads country boundary data from the world-atlas TopoJSON file hosted on jsDelivr, then extracts India’s geometry with `topojson.feature`. The code uses `d3.geoMercator` and `d3.geoPath` to project and draw the shape, fitting it to a 960×500 viewport via `fitSize`.
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.
MIT Licensed








Comments
Sign in to join the discussion.