Skip to main content
100%

Circles with random color picker

✓ Published0🌍 Public
NNita
Last edited Feb 25, 2020
Created on Feb 24, 2020

This example renders a grid of circles on an SVG canvas using React. The visualization generates 201 circles positioned along the x-axis at regular increments, with random y-coordinates between 0 and 400. Each circle’s fill color is determined by its index position, producing an RGB value that shifts across the spectrum. The code uses React’s `ReactDOM.render` to mount the component and maps over an array to create the SVG circle elements. A fixed viewport of 960 by 500 pixels contains the randomly scattered circles against a light green background.

AI-generated description

React Starter code.

MIT Licensed

Similar vizzes