const scopeHandler = {
set: function(obj, prop, value) {
console.log(`${prop} changed from ${obj[prop]} to ${value}`);
obj[prop] = value;
return true;
}
};
const scopeProxy = new Proxy(window.app, scopeHandler);
So I'm trying to detect any changes whenever app or any of its children app.reports changes, but it doesn't log anything. What am I doing wrong?