How to create a global variable in Client side JS, where the variable should not be accessible from browser console ? I tried using let, it did not work (the code below is not in a function it is in a script file)
let data={
"data-item":"Secure Data"
};
I also tried adding data in a class and using an instance of it but the instance is also accessible from console. The variable is an object and will be modified dynamically by user interaction, so cannot freeze the object either.