https://kotlinlang.org logo
e

Erik

07/01/2022, 2:03 PM
How can I respond to the user pressing Enter/Return on a
TextInput
or
NumberInput
? I hoped that adding this would work:
Copy code
addEventListener("submit") {
    onSubmit()
    it.preventDefault()
}
And I also tried the
"onkeyup"
event, but I can't seem to trigger a callback. Must I use a
Form
for this, or can it be done without one?
5 Views