0.7.4 • Published 3 years ago

@slice-and-dice/govuk-react-text-area v0.7.4

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

TextArea

Import

  import TextArea from '@govuk-react/text-area';

Usage

Simple

<TextArea name="group1">Description of what you saw</TextArea>

TextArea with hint text

<TextArea name="group1" hint={['Enter as many words as you like']}>
  Description of what you saw
</TextArea>

TextArea with hint text & error

const meta = {
  touched: true,
  error: 'Example',
};

<TextArea
   name="group1"
   hint={['Enter as many words as you like']}
   meta={meta}
 >
   Description of what you saw
 </TextArea>

References:

Properties

PropRequiredDefaultTypeDescription
childrentrue | node
hintundefinedstring
input{}shapeobject Object
meta{}shapeobject Object