Skip to content

Commit 61b43ca

Browse files
author
Dipak Sarkar
committed
updated component
1 parent 0cc2203 commit 61b43ca

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/component.vue

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,19 @@ export default {
5858
emits: ['update:modelValue'],
5959
data() {
6060
return {
61-
maskedValue: this.modelValue,
61+
maskedValue: null,
6262
unmaskedValue: null
6363
}
6464
},
6565
watch: {
6666
masked() {
67-
this.$emit('input', this.emittedValue)
67+
this.$emit('update:modelValue', this.emittedValue)
68+
},
69+
modelValue: {
70+
deep: true,
71+
handler (val) {
72+
this.maskedValue = val
73+
}
6874
}
6975
},
7076
methods: {

0 commit comments

Comments
 (0)