Nodejs Array Skip skipUntil(fun)

Here you can find the source of skipUntil(fun)

Method Source Code

Array.prototype.skipUntil = function (fun) {
    var result = new Array(), index = 0;
    while (!fun(this[index])) {
        index++;/*w  ww  . j  a  v a 2s  . c  om*/
    }
    return this.skip(index);
};

Related

  1. skip(count)
    Array.prototype.skip = function (count) {
        return this.slice(count);
    };
    
  2. skip(skipNumber)
    Array.prototype.skip = function(skipNumber){
       return this.slice(skipNumber);
    };
    
  3. skipWhile(fun)
    Array.prototype.skipWhile = function (fun) {
        var result = new Array(), index = 0;
        while (fun(this[index])) {
            index++;
        return this.skip(index);
    };
    
  4. skipWhile(predicate)
    Array.prototype.skipWhile = function (predicate) {
      predicate = predicate || Predicate;
      var l = this.length;
      var i = 0;
      for (i = 0; i < l; i++)
        if (predicate(this[i], i) === false) break;
      return this.skip(i);
    };