Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Sleect with React

Public visualization

Viewing a saved revision (read-only)

0571afb3ebb94d36bbc619941433824f

Sleect with React

0 stars0🌍 Public
MManon ROMAIN
Last edited Oct 18, 2021
Created on Oct 18, 2021

This example demonstrates a simple React component for selecting a pet from a dropdown menu, with the chosen value managed through React’s `useState` hook and displayed in the browser console. The `Dropdown` component renders a native HTML `<select>` element, mapping over an array of options to generate `<option>` tags, and invokes a callback `onSelectedValueChange` upon user interaction. The styling is applied via CSS, and ReactDOM renders the App component into the root div. It uses React 17 and D3 v7 for the underlying libraries.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.