`undefined` Is A Global

It is relevant because you are putting up a smokescreen of deceptive words against the commonsense idea of a global name. 'undefined', where it is defined in globalThis is not a variable, because you can't vary it. So, as you allude to, it would be incorrect to call it a global variable. But that's not because it isn't global; it's because it isn't a variable. The evidence both in Node and in a slightly-retarded browser that I use indicates that the name 'undefined' is present as a key in globalThis, and that the parser treats the word "undefined" not as a keyword, like "false" is, but as an identifier, like "foo" is.

Your mention of 'boolean' is not germane here; it is a string with a special meaning that is the value of some typeof expressions, and there is nothing about the fact that those strings come up in that context that bears one way or the other on whether the identical strings are or are not used as global names, or can or cannot be used as identifiers.

/r/learnjavascript Thread Parent