Javascript Array delete(index)

Description

Javascript Array delete(index)


'use strict';//from  w  ww.  j a  va 2s. c  o m

Array.prototype.delete = function (index) {
    delete this[index];
    this.splice(index, 1);

    return this;
};

Array.prototype.extend = function (newItems) {
    return this.push.apply(this, newItems);
};



PreviousNext

Related