code: function guessBestFile(componentName, files) {
  			var minDist = 1e13;
  			var minDistIndex = -1;
  
  			files.sort(function(a, b) {
  				// Reverse order by path length
  				return b.length - a.length;
  			});
  
  			files.forEach(function(filepath, i) {
  				var filename = path.basename(filepath, '.js');
  				var dist = _.str.levenshtein(componentName, filename);
  				if (dist <= minDist) {
  					minDist = dist;
  					minDistIndex = i;
  				}
  			});
  
  			if (minDistIndex !== -1) {
  				return files[minDistIndex];
  			}
  			else {
  				return undefined;
  			}
  		}
docs: Computing Levenshtein distance to guess a main file.
  Based on https://github.com/curist/grunt-bower
  
  @param {String} componentName Component name.
  @param {Array} files List of all possible main files.
  @return {String}