js hook dom


var _appendChild = Node.prototype.appendChild;
Node.prototype.appendChild = function(){
    console.log("Hook appendChild");
    return _appendChild();
};
Node.prototype.appendChild = new Proxy(
    Node.prototype.appendChild,{
        apply:function(){
            var retval = Reflect.apply(trapTarget.thisArg,argumentList);
            console.log("appendChild retval:",retval);
            return retval;
         }
?
   }
);