In jQuery, we can check if a textarea is empty or not using the following code:
var oldVal = "";
$("#textarea").on("change keyup paste", function() {
var currentVal = $(this).val();
if(currentVal == oldVal) {
return; //check to prevent multiple simultaneous triggers
}
oldVal = currentVal;
//action to be performed on textarea changed
alert("changed!");
});
Your method of telling the whole thing in this article
is in fact pleasant, all be able to easily be aware of it, Thanks a lot.