I'm trying to extract selector from the event.currentTarget
(e,g input#lst-ib.gsfi
). I can find other attributes like event.currentTarget.baseURI
. May I know how can I get input#lst-ib.gsfi
? Following console output has all the details about the object. I can get originalEvent.path
as array of object. But not sure how to get the title/name (what ever it is called)
Thanks a lot in advance for all of your help.
currentTarget:input#lst-ib.gsfi
accept:""
accessKey:""
align:""
alt:""
assignedSlot:null
attributes:NamedNodeMap {0: class, 1: id, 2: maxlength, 3: name, 4: autocomplete, 5: title, 6: type, 7: value, 8: aria-label, 9: aria-haspopup, 10: role, 11: aria-autocomplete, 12: dir, 13: spellcheck, 14: style, class: class, id: id, maxlength: maxlength, name: name, autocomplete: autocomplete, …}
autocapitalize:"sentences"
autocomplete:"off"
autofocus:false
baseURI:"https://www.google.ca/search?ei=fnSHWtmQOcPcswWo67yYBA&q=get+object+name+javascript&oq=getobject+name+&gs_l=psy-ab.3.0.0i22i30k1l10.2185.66281.0.69197.18.18.0.0.0.0.201.1902.4j12j1.17.0....0...1.1.64.psy-ab..1.17.1900...0j46j33i160k1j33i21k1j35i39k1j0i131i67k1j0i131k1j0i67k1j0i46k1j0i20i263k1j0i10k1.0.rFRsim4bz6g"
checked:false
childElementCount:0
childNodes:NodeList []
children:HTML