vue-better-sync
3.2.3 • Public • Published vue-better-sync
Simply sync values.
Install
CDN:
UNPKG
|
jsDelivr
(available as window.VueBetterSync
)
Usage
Inside your Vue components:
<template>
<input
v-model="localValue"
@input="handleInput"
/>
</template>
<script>
import VueBetterSync from 'vue-better-sync'
export default {
mixins: [
VueBetterSync({
prop: 'value',
event: 'input'
})
],
props: {
value: String
},
methods: {
handleInput(e) {
this.syncValue(e.target.value)
}
}
}
</script>
Readme
Keywords
nonePackage Sidebar
Install
Weekly Downloads