jQuery blur() MethodThe blur event occurs when an element loses focus. The blur() method triggers the blur event, or attaches a function to run when a blur event occurs. Tip: This method is often used together with the focus() method.
In jQuery by using blur() property we can remove focus from input textbox field.
Use the blur() method to remove the focus from an element, e.g. input. blur() . If you need to remove the focus from the currently active element without selecting it, call the blur method on the activeElement property - document.
blur() method removes keyboard focus from the current element.
$('#textarea').blur()
Documentation at: http://api.jquery.com/blur/
Based on your question, I believe the answer is how to trigger a blur, not just (or even) set the event:
$('#textArea').trigger('blur');
Guess you are looking for .focusout()
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With