Nodejs Array Empty Check isEmpty()

Here you can find the source of isEmpty()

Method Source Code

Array.prototype.isEmpty = function () {
    return this.length === 0;
};

Related

  1. isEmpty()
    Array.prototype.isEmpty = function(){
      return (this.length === 0 );
    
  2. isEmpty()
    Array.prototype.isEmpty = function() {
        return (0 === this.length);
    
  3. isEmpty()
    Array.prototype.isEmpty = function() {
      return this.length == 0;
    };
    
  4. isEmpty()
    Array.prototype.isEmpty = function() {
        return this.length == 0;
    
  5. isEmpty()
    Array.prototype.isEmpty = function() { 
      return this.length < 1 
    };
    
  6. isEmpty()
    Array.prototype.isEmpty = function() {
      return this.length == 0 ? true : false;
    };
    
  7. is_empty()
    Array.prototype.is_empty = function() {
      return is_empty(this);
    };