摘记: 当调用test2时: ```javascript methods = { test(age){ console.log('test', age); }, test2(){ console.log(this.methods); this.methods.test('222') ..

当调用test2时:

methods = {
    test(age){
      console.log('test', age);
    },
    test2(){
      console.log(this.methods);
      this.methods.test('222');
      console.log('test2')
    }
  };

结果:

{test: f, test2: f}
test 222
test2

原文地址: https://blog.csdn.net/qq_35790269/article/details/81478467