Skip to main content
100%

test

✓ Published0🌍 Public
EEd Smale
Last edited Jul 16, 2023
Created on Jul 16, 2023

This example demonstrates how SVG shapes can fill a browser window using D3.js. The code appends a red rectangle covering the entire viewport, then adds 100 horizontal bars stacked vertically with 10-pixel gaps. Each bar spans the full window width, creating a striped overlay effect. The visualization uses D3 selections with the `range()` generator and `.join()` method to bind data to SVG `<rect>` elements. All rendering occurs through SVG, with dimensions dynamically derived from `window.innerWidth` and `window.innerHeight`.

AI-generated description

A demo of SVG shapes.

MIT Licensed

Similar vizzes