Radio group
A list of options where only one can be chosen.
Add it to your project
Or install the packages yourselfTerminal
npm install @heroui/react
First time with HeroUI? Set it up once.
The code
* controls.
*/
import {Description, Label, Radio, RadioGroup} from "@heroui/react";
export default function RadioGroupDemo() {
return (
<RadioGroup defaultValue="premium" name="plan">
<Label>Plan selection</Label>
<Description>Choose the plan that suits you best</Description>
<Radio value="basic">
<Radio.Content>
<Radio.Control>This comes with paid plans
The code for every component comes with paid plans, along with the rest of the AI toolkit. The first component under each heading is free.
Changed for this site: A default export (HeroUI's docs use named ones) without the docs site's prop controls.