It's not always safe to use this trick to query an element. For example, if you have <div id="alert" /> on a page, accessing window['alert'] will not return the element you're looking for.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
It's not always safe to use this trick to query an element. For example, if you have
<div id="alert" />
on a page, accessingwindow['alert']
will not return the element you're looking for.