Typescript Get Index Of Object Javascript Mdn Dom Js