Categories
Current Searches

How can I check for “undefined” in JavaScript? – Stack Overflow

If it is undefined, it will not be equal to a string that contains the characters “undefined”, as the string is not undefined. You can check the type of the variable: