Skip to main content
100%

D3 Blank Canvas

✓ Published1🌍 Public
YYoung Song
Last edited Jun 20, 2022
Created on Jun 20, 2022
Forked from D3 Face

This example demonstrates a minimal D3.js setup that fills the browser viewport with a blank SVG canvas. It renders a single rounded rectangle that covers the entire screen, using `d3.select` and the `svg.append` method to add the shape. The code reads the document body’s client width and height to size the SVG dynamically, and the stylesheet fixes the body to prevent scrolling. The example highlights basic SVG attribute manipulation with `attr` for width, height, and corner radius, serving as a clean starting point for D3 projects.

AI-generated description
MIT Licensed

Similar vizzes