I have an online tool, I have built with rails that takes a user input and output the result on the same page upon clicking a button. Upon clicking the button a complex code runs on the input and shows the result. How can I make the result appears while the user is typing the input, like real time capturing processing of the input. I am using Rails 5.1.4 and Ruby 2.4.2p198
Asked
Active
Viewed 77 times
0
-
4Run your code in a handler for an event like `keyup`. – Barmar Feb 06 '18 at 20:45
1 Answers
1
You can bind keyup
function and execute the handler function at real time when user types instead of when submit is clicked, I've created a simple fiddle, have a look

Subash
- 3,128
- 6
- 30
- 44