hacking-Array

Is it possible to hack [item,item,item,....] by hacking the Array object?
答えを急げば、これは無理である。
"use strict" const orginalArray=window.Array; window.Array=function(...args){ console.log("inside the dummy Array constructor"); return new orginalArray(...args); }; const a1=new Array(10,20,30,40); console.log("[a1]",a1); const a2=[1,2,3,4]; console.log("[a2]",a2);
dummy関数の設置は[a1]には影響を及ぼすが、[a2]には影響をおよぼさない。 See console...