v-model modifiers can break emitting an update event if some parameter is not a string
Version
3.2.33
Reproduction link
Steps to reproduce
- Click ""update" button -> no error
- Click "update with extra data" -> error
a.trim is not a function
What is expected?
I would like to pass any type of value to update:xxx event
What is actually happening?
If v-model is used with built-in modifiers, e.g. trim or number then I cannot emit the update:xxx event if passed some parameter is not a string. Let's say i have custom Input component where I would like to pass additional data to update:modelValue
event, e.g. an object with field name but currently, as shown in the demo, if I use trim modifiers, emitting such an event is not possible.
Looks like the issue is in these lines of code componentEmits.ts#L124