Here you can find the source of remove( from, to )
/**// w ww . jav a2 s. c o m * @module QueenEngine * @submodule Array */ /** * * * @method remove * @param {Int} from * @param {Int} to * @example * var a = [ 3, 4, 5 ]; * a.remove( 1 ); */ Array.prototype.remove = function( from, to ) { var rest = this.slice( ( to || from ) + 1 || this.length ); this.length = from < 0 ? this.length + from : from; return this.push.apply( this, rest ); };
Array.prototype.remove = function( from, to ) { if( typeof from == 'object' ) { var idx = this.indexOf( from ); if( idx >= 0 ) return this.remove( idx ); return this; else { var rest = this.slice((to || from) + 1 || this.length); this.length = from < 0 ? this.length + from : from; ...
Array.prototype.remove = function( from, to) var rest = this.slice((to || from) + 1 || this.length); this.length = from < 0 ? this.length + from : from; return this.push.apply(this, rest); };
Array.prototype.remove= function(){ var what, a= arguments, L= a.length, ax; while(L && this.length){ what= a[--L]; while((ax= this.indexOf(what))!= -1){ this.splice(ax, 1); return this; ...
Array.prototype.remove = function() { var what, a = arguments, L = a.length, ax; while (L && this.length) { what = a[--L]; while ((ax = this.indexOf(what)) !== -1) { this.splice(ax, 1); return this; ...