Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Smiley Face Part II

Public visualization

Fork of Smiley Face Part II

0 stars0🌍 Public
LLawrence Liu
Last edited Apr 12, 2022
Created on Apr 9, 2022

This example shows a pet selector using a dropdown menu with options like Goldfish, Dog, Cat, Hamster, Parrot, and Spider. The selected value is managed through React's `useState` hook, displayed in the console. The `Dropdown` component receives options and state setters as props, rendering a `<select>` element that updates the state on change. The code combines React 16.9 with D3 v7, specifically using the `range` function from D3, though no data visualization is rendered beyond the interactive dropdown interface.

AI-generated description

React Starter Code

Comments

Sign in to join the discussion.

MIT Licensed