Below is the code for checking the Empty Strings present in the Java Script
string str;
if(str != ‘undefined’ && str != null && str != ” && str != undefined && str != ‘null’ && str != ‘ ‘ && str.trim() != ”)
{
// if string is not empty do your logic
}
else // if string is empty
{
do your logic
}
Using this we can check the empty strings in JavaScript.
– Sumanth A [10/25/18]