0.3.0 • Published 5 years ago

v-autosize-input v0.3.0

Weekly downloads
20
License
MIT
Repository
github
Last release
5 years ago

v-autosize-input

Support Vue 2 Version License

Yet another Vue directive to change <input> width automatically by content length. It works well on IME by using autosize-input internally.

Edit v-autosize-input demo

The most of implementation has copied and translated to TypeScript from vue-autosize. See LICENSE.orig for the original license.

Install

npm i v-autosize-input

Usage

import Vue from 'vue';
import VAutosizeInput from 'v-autosize-input';

Vue.use(VAutosizeInput);

Then use autosize-input directive on <input> element like:

<input type="text" v-autosize-input />

See ./example/src/App.vue for more detail.

Comparison

NameReason
vue-autosizeWorks well on IME but seems not maintained
vue-input-autowidthDoes not work on IME

See also

If you need autosize feature on textarea, v-autosize, which has forked from vue-autosize, seems good choice.