Documentation
Label

Label

Bundle size
1.2 KB
0.0.3

Renders a label in an accessible form, with its respective controls.

Installation

pnpm add @inpulse-ds/label

Usage

import { Label } from "@inpulse-ds/label";
 
return (
  <Label for="example">Text</Label>
);

API

The for property must reflect the name of the field to which the Label is related.

PropTypeDefault valueRequired
forstring-Yes
valuestring-No

Examples

Using children

This is the default application, which allows greater possibilities by accepting any content, including JSX elements.

Using value

This application is optional and only accepts string.