4 ms·
undefined and null are quite different. It's impossible to test for undefined. You cannot expect (x == undefined) to return true. It would result in exception,
by jganetsk 15y ago
undefined and null are quite different. It's impossible to test for undefined. You cannot expect (x == undefined) to return true. It would result in exception, in fact. You can only safely make a value undefined if you guarantee it won't be used.