Vuetify: 0.17.6
Vue: 2.5.13
Browsers: Chrome 63.0.3239.132
OS: Mac OS 10.13.1
Given I've entered text into a v-text-field and the underlying value has changed
When I press enter
I expect the change event to fire
The enter key does not trigger the change event.
https://codepen.io/johnjleider/pen/ypKvMJ?editors=1111
As discussed on Discord, the surface area of this change could be quite big.
I don't expect the change event to fire on enter. Why should it?
@smares My rationale (and what prompted me to pose the initial question) was that native inputs behave this way. After you've typed something new, hitting enter triggers the change event.
Hmm, indeed. HTML4 specs say "The onchange event occurs when a control loses the input focus and its value has been modified since gaining focus. This attribute applies to the following elements: INPUT, SELECT, and TEXTAREA." WHATWG however says "The change event fires when the value is committed, if that makes sense for the control, or else when the control loses focus.". Not sure if they specify anywhere what "committed" means.
Quite new to vue/vuetify, but I would expect the event to be passed on input change (@input) also. At least this is the behaviour I get if I use a conventional input field. I have been trying for the last hour or so but I cannot seem to get
Ok, managed to get it to work with @input.native.
Most helpful comment
Ok, managed to get it to work with @input.native.