v-autosize
Lightweight Vue wrapper for autosize.
Use v-autosize
directive on the textarea
element to make it automatically adjust height to fit text.
Install
npm install v-autosize
Usage
Register directive locally in the component
; // Your component directives: autosize
Or register directive globally in the root Vue instance
;; Vue;
Use v-autosize
directive on the textarea
element
Comparison
- This module: 3.7 kB Minified, 1.3 kB Gzipped
vue-autosize
: 5.2 kB Minified, 1.9 kB Gzippedvue-textarea-autosize
: 3.5 kB Minified, 1.4 kB Gzipped. A component is used instead of a directive.
License
MIT License