Cleans up an instance name to create shorter/less noisy names.
Example: `<app@component:textarea::ember545>` becomes `textarea`.

@method cleanupInstanceName
@param  {String} name
@return {String} The short/cleaner name
171795
function cleanupInstanceName(name) {
  let match = name.match(/^.+:(.+)::/);
  if (!match) {
    // Support for Namespace names (instead of module) (for the tests).
    // `<App.ApplicationController:ember301>` => `App.ApplicationController`
    match = name.match(/^<(.+):/);
  }
  if (match) {
    return match[1];
  }
  return name;
}
441734
@VisibleForTesting
  static Name simple(String name) {
    switch (name) {
      case ".":
        return SELF;
      case "..":
        return PARENT;
      default:
        return new Name(name, name);
    }
  }
829222
function (name) {
		var elem = this.createElement('g');
		return defined(name) ? elem.attr({ 'class': PREFIX + name }) : elem;
	}
165259
public final static String clearName(String name)
    {
        boolean stripDots = false;
        boolean ascii = true;
        return clearName(name, stripDots, ascii);
    }
1047765
function(name) {
			name = (name || '').toLowerCase();
			
			if (name in elementMap)
				return this.getMapping(name);
			
			if (this.isInlineLevel(name))
				return 'span';
			
			return 'div';
		}
247731
function(elem, name) {
  if (!elem.attribs || !hasOwn.call(elem.attribs, name))
    return;

  delete elem.attribs[name];
}
1028005
function (parsedName) {
      parsedName.name = parsedName.name.replace(/\./g, '_');
      if (parsedName.name === 'basic') {
        parsedName.name = '';
      }
    }
233346
function (name) {
        var newName;
        if (gpf.xml.isValidName(name)) {
            return name;
        }
        // Try with a starting _
        newName = "_" + name;
        if (!gpf.xml.isValidName(newName)) {
            gpf.Error.xmlInvalidName();
        }
        return newName;
    }
771602
function(name) {
    var nameList = name.split('.');

    return nameList
      .map(function(item, i, list) {
        return list.slice(0, i+1).join('.');
      })
      .filter(function(item) {
        return item !== null;
      });
  }
176269
function (name) {
            var self = this;
            var __attrVals = getAttrVals(self);
            var __attrs = self.getAttrs();
            if (self.hasAttr(name)) {
                delete __attrs[name];
                delete __attrVals[name];
            }
            return self;
        }
431343
def sanitize_name(name, prefer = nil)
      path = name.to_s

      # Check if we haven't got an extension
      # we'll assume you're looking for prefer or "html" otherwise
      path += ".#{prefer || 'html'}" unless File.basename(path).include?(".")

      path
    end
611374
function (fullName) {
      if (this.resolver && this.resolver.normalize) {
        return this.resolver.normalize(fullName);
      } else if (this.fallback) {
        return this.fallback.normalizeFullName(fullName);
      } else {
        return fullName;
      }
    }
638892
function(name) {
            if (/[A-Z]/.test(name.charAt(0)))
                return "default" + name;
            var firstLetter = name.charAt(0);
            return "default" + firstLetter.toUpperCase() + name.substring(1);
        }
743925
private String prepareName(String name) {
        // \s = A whitespace character: [ \t\n\x0B\f\r]
        String[] arr = name.split("\\s");
        List<String> list = new ArrayList<>(arr.length);
        for (int i = 0; i < arr.length; i++) {
            String rewrite = NON_WORD_CHAR.matcher(toLowerCase(arr[i])).replaceAll("");
            String tmp = rewriteMap.get(rewrite);
            if (tmp != null)
                rewrite = tmp;
            // Ignore matching short frases like de, la, ...
            if (!rewrite.isEmpty() && rewrite.length() > 2) {
                list.add(rewrite);
            }
        }
        return listToString(list);
    }
241848
function (name) {
    // pre-test to improve performance
    if (REGEXP_IS_ESCAPED.test(name)) {
        name = name.replace(REGEXP_DOT, '.');
        name = name.replace(REGEXP_DOLLAR, '$');
        name = name.replace(REGEXP_TO_BSON, 'toBSON');
        name = name.replace(REGEXP_BSON_TYPE, '_bsontype');
    }

    return name;
}
769669
function getInstanceNameFromElement(element) {
  let nameFromName = getAttribute(element, 'name');

  if (nameFromName !== null && nameFromName !== undefined && nameFromName !== '')
    return nameFromName;
  else
    return null;
}
821645
function (name, separator) {
                var sep = separator || (name.indexOf(".") !== -1 ? "." : "/"),
                    fullName = this.fullSchemaName(name, sep);
                return fullName.substring(fullName.lastIndexOf(sep) + 1);
            }