Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-textarea

Package Overview
Dependencies
Maintainers
3
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-textarea

React Textarea

  • 1.0.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-50%
Maintainers
3
Weekly downloads
 
Created
Source

react-textarea

<textarea /> replacement

with autoGrow and resize support

Motivation

  • Most often you only need the textarea value on the onChange handler. Just as often, you don't need change event propagation.

  • autoGrow is a very nice to have feature on a textarea. Coupled with maxHeight and resize

Props

  • onChange(value: String [, event ]): Function - the onChange handler will be called with the textarea value, not the event object as first argument. The event object is the second arg to the callback function.
  • stopChangePropagation: Boolean - defaults to true. By default, the propagation of the change event will be stopped. All other evens will work as usual. Set this prop to false to allow change event propagation.
  • autoGrow: Boolean - defaults to true.
  • resize: Boolean|String - defaults to true - making the textarea resizable in both directions. Pass false or String to change this behaviour.
  • maxHeight: Number|String - the max height the textarea can have.

Development

$ npm run dev

and navigate to localhost:9090.

See react-field for <input /> replacement.

Thanks

Thanks to @andreypopp and his initial implementation at https://github.com/andreypopp/react-textarea-autosize

License

MIT

Keywords

FAQs

Package last updated on 03 Feb 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc