JQuery change not firing until blur

according to the right answer here Javascript change event on input element fires on only losing focus

you should do something like this

$('#name').on('change textInput input', function () {
       
});

however I found that having both textInput and input events can cause the event to fire twice, you don’t want that, so just do

$('#name').on('change input', function () { ...

Leave a Comment