javascript setningafræði til að athuga núll eða óskilgreind eða tómur
if (typeof value !== 'undefined' && value) {
//deal with value'
};
javascript athuga hvort strengurinn er tóm
var string = "not empty";
if(string == ""){
console.log("Please Add");
}
else{
console.log("You can pass"); // console will log this msg because our string is not empty
}