If I want to access a variable define in the global context from within a scope where there already exists a variable with the same name:
var variable = 'value';
function someScope(variable){
variable = 'not this';
var global = Function('return this')();
console.log('this > ', global.variable);
}
Is it possible to still access the global variable somehow?
Neither the global
object nor getting the Global object works. (global.variable
returns undefined)