Skip to main content
Public

Share visualization

Loading preview…

Sol Lewitt - D3 multi shapes

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

Sol Lewitt - D3 multi shapes

0 stars1Public
Hhquazza@gmail.com
Last edited Dec 27, 2024
Created on Dec 27, 2024

This example recreates Sol Lewitt-inspired geometric art using D3.js, rendering a grid of horizontal and vertical rectangles that are selectively masked by overlapping symbols. The visualization displays five distinct shapes—including circles, crosses, and diamonds—positioned at the center of the canvas. The code uses `d3.select`, `d3.range`, `d3.symbols`, and `d3.symbol` to generate SVG paths, while SVG masks with inverted black-and-white fills determine which grid lines remain visible. The final pattern emerges from alternating mask states applied to the two perpendicular line sets.

AI-generated description

Trying to reproduce Sol Lewitt art in D3.

To know which version is the latest D3, go to Unpkg.com - when produced, latest version was D3.7.9

package.json --> used to pull in D3.js latest version

Comments

Sign in to join the discussion.

MIT Licensed