This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* tests for all the ways a variable might be undefined or not have a value | |
* @param {*} x the variable to test | |
* @return {Boolean} true if variable is defined and has a value | |
*/ | |
function isDefined(x) { | |
if ( x === '' || x === null || x === undefined) { | |
return false; | |
} | |
return true; |
NewerOlder