SOURCE

(function (){
    let subProto = Object.create(Array.prototype)
    subProto.push = function(...args){
        // ...todo
        console.log('new push')
        Array.prototype.push.call(this, ...args)
    }

    // import subProto from ''

    let arr = [1,2,3]
    arr.__proto__ = subProto;
    arr.push(4)
})()

let arr = [1,2,3];
arr.push(4)
console 命令行工具 X clear

                    
>
console