Answer the question
In order to leave comments, you need to log in
How to refer to input value?
<input @change = "doSomethingWithValue( this.value )" /> // Так не работает
<input @change = "doSomethingWithValue(" + this.value + ")" > // ...и так тоже
Answer the question
In order to leave comments, you need to log in
<input @change="doSomethingWithValue" />
methods: {
doSomethingWithValue(e) {
const value = e.target.value;
...
<input @change="doSomethingWithValue($event, 'hello, world!!')" />
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question