conicConformalSpain example
This example uses the geoConicConformalSpain composite projection from d3-composite-projections to render an interactive map of Spain's provinces from TopoJSON data. The SVG visualization displays each province as a light green polygon with thin black strokes, and includes a red outline showing the composition borders where the projection joins the Canary Islands and the mainland. Hovering over a province triggers a smooth transition to red, and moving the mouse away transitions it back to the original color, demonstrating animated interactivity with d3-transition.
AI-generated descriptionThis file shows how to use the geoConicConformalSpain projection from d3-composite-projections.
To change the file, edit draw.js and run
browserify draw.js| uglifyjs > bundle.js
The dependencies are installed with:
npm install d3-composite-projections d3-geo d3-request d3-selection d3-transition topojson