The value of a variable is {}
i am trying to check if its empty or not using if statement.
I have tried the following
if(val)
{
console.log("NOT EMPTY");
}
else
{
console.log("EMPTY");
}
But this returns NOT EMPTY, meanwhile the array is empty...please help.i am using IONIC