getProperAttributeCase(element, attribute) {
      var _$properlyCasedAttrib, _$properlyCasedAttrib2;

      const roots = "svg, math, :root"; // Potential root elements

      const root = element.closest(roots).tagName;
      (_$properlyCasedAttrib2 = (_$properlyCasedAttrib = _.properlyCasedAttributesCache)[root]) !== null && _$properlyCasedAttrib2 !== void 0 ? _$properlyCasedAttrib2 : _$properlyCasedAttrib[root] = {};
      let attr = _.properlyCasedAttributesCache[root][attribute];

      if (attr) {
        return attr;
      }

      const tag = element.tagName;
      let doc = new DOMParser().parseFromString("<".concat(root, "><").concat(tag, " ").concat(attribute, "=\"\"></").concat(tag, "></").concat(root, ">"), "text/html");
      attr = doc.body.firstElementChild.firstElementChild.attributes[0].name;
      _.properlyCasedAttributesCache[root][attribute] = attr;
      return attr;
    }
Get the element identified by the URL hash