Skip to main content
100%

d3 drop shadow example

✓ Published0🌍 Public
Aackuser
Last edited Mar 19, 2013
Created on Aug 28, 2020

Three steelblue rectangles with drop shadows are drawn on an SVG canvas using D3.js v3. The example demonstrates SVG filter effects, specifically `feGaussianBlur`, `feOffset`, and `feMerge`, to create a blurred, offset shadow behind each rectangle. Data is stored in a simple JavaScript array of coordinates, and `d3.select` and `selectAll` bind this data to the rectangles, applying the filter via the `style("filter", ...)` attribute. The code is based on a gist by ackuser and uses D3’s SVG rendering.

AI-generated description

Similar vizzes