I need to know if I can verify if user pressed a key or not only with onchange
event, because I get the text on input with a QR reader, but there also exists the possibility for the user to manually enter the data.
I have this code (example):
_getValue = (event) => {
let value = event.target.value;
}
render() {
<input type="text" onChange={this._getValue} />
}
So, on _getValue
method, which is from an onchange
event, I need to check if the change is coming from a key or from the QR reader.
Thank you to all!