Vue使用Proxy监听所有接口状态的方法实现

2020-06-13 10:39:30易采站长站整理

console.log(proxy.name); // "proxy"
console.log(target.name); // "proxy"
// 抛出错误
proxy.anotherName = "proxy";

另外vue3.0 的响应式也是使用的代理