Skip to main content
100%

Assignment 2 World map

✓ Published1🌍 Public
Ppasyasahas
Last edited Jul 21, 2023
Created on Jul 21, 2023
Forked from Hello VizHub

This example displays a world map drawn as SVG paths, with countries filled in light gray and outlined in red. It loads country boundary data from a remote GeoJSON file using `d3.json`, then applies the `d3.geoMercator` projection with `fitSize` to fit the map into an 800×600 viewport. The `d3.geoPath` generator creates the path data for each feature. The map is rendered on a light gray background, and the styling uses CSS to control fill and stroke colors.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes