Javascript 如何在流中扩展数组?
我想使用原型扩展一个数组。如何在Flow中执行此操作Javascript 如何在流中扩展数组?,javascript,flowtype,Javascript,Flowtype,我想使用原型扩展一个数组。如何在Flow中执行此操作 Array.prototype.equals = function(compare): boolean { return Array.isArray(compare) && !(this < compare || compare < this); }; 什么是Array2?这就是你要找的吗?嘿,对不起,那是个错误!谢谢你的评论,我更新了这个问题。似乎仍然无法使用flow(像许多其他东西一样)。。。这就解释了,
Array.prototype.equals = function(compare): boolean {
return Array.isArray(compare) && !(this < compare || compare < this);
};
什么是Array2?这就是你要找的吗?嘿,对不起,那是个错误!谢谢你的评论,我更新了这个问题。似乎仍然无法使用flow(像许多其他东西一样)。。。这就解释了,谢谢!什么是Array2?这就是你要找的吗?嘿,对不起,那是个错误!谢谢你的评论,我更新了这个问题。似乎仍然无法使用flow(像许多其他东西一样)。。。这就解释了,谢谢!
[1,2,3].equals([1,2,3])