Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/component/inputarea

single-line / multi-line hybrid input (multi-line triggered via shift+return)
https://github.com/component/inputarea

Last synced: 13 days ago
JSON representation

single-line / multi-line hybrid input (multi-line triggered via shift+return)

Awesome Lists containing this project

README

        

# inputarea

Cross between a textarea and text input. The textarea behaves like
a single-line input unless the return key is used. A "multiline" classname
is added to aid styling, for example you may wish to expand the field height.

## Installation

Install with [component(1)](http://component.io):

$ component install component/inputarea

## Example

```js
var inputarea = require('inputarea');
var el = document.querySelector('textarea');

inputarea(el).on('input', function(str){
console.log(str);
});
```

## License

MIT