I just played around with global declerations using var, const, and without any, and noiticed that while var and without can be accessed using globalThis, const cant.
aaa = "aaa";
var bbb = "bbb";
const ccc = "ccc";
console.log(globalThis.aaa, globalThis.bbb, globalThis.ccc); // logs: aaa bbb undefined
My question is, is there a way to access them using window or globalThis? And if not where else are they?
As they are global there is not really any practical need for this, I'm just curious.