code: function size(collection) {
    var x, i = 0;
  
    if ('object' === type(collection)) {
      for (x in collection) i++;
      return i;
    }
  
    return +collection.length;
  }
docs: Determine the size of a collection.
  
  @param {Mixed} collection The object we want to know the size of.
  @returns {Number} The size of the collection.
  @api public